function myInstanceOf(left, right) {
if (left === null || typeof left !== 'object') return false;
if (typeof right !== 'function') throw new Error('right must be function')
let L = left.__proto__;
let R = right.prototype;
while(L !== null) {
if (L === R) return true;
L = L.__proto__;
}
return false;
}