call
Function.prototype.myCall = function (){
const args = Array.prototype.slice.call(arguments)
const thisObj = args[0]
Object.prototype.runOuterMethod = this
args.splice(0,1)
thisObj.runOuterMethod(...args)
delete Object.prototype.runOuterMethod
}
apply
Function.prototype.myApply = function (thisObj, args){
Object.prototype.runOuterMethod = this;
thisObj.runOuterMethod(...args);
delete Object.prototype.runOuterMethod
}