filter() polyfills
//Polyfill for filter()
Array.prototype.myFilter = function (callBack){
let temp = []
for(let i= 0;i<this.length;i++){
if(callBack(this[i],i,this)) temp.push(this[i])
}
return temp
}
const arr = [5,7,89,3,2,490,75]
const filteredArr = arr.myFilter(each => each % 2 === 1 )
console.log(filteredArr)