Ok so i need to recreate the find method but i cant manage to suceed. I am trying to do this but everytime i run this on a array it simple returns me an error
array.prototype.findDaShopee = function ( ok ) {
for (let i = 0; i < this.length; i++) {
if (this[i] == ok[i]) {
return this[i]
})
}
}
but it's not working
I tried removing the 'ok' function, i tried everything, i dont want the answer just the explanation
i'm really tring to understand