I want to find the attributes I want inside the object.
There is one object.
let obj = {
1: {
2 : {
3: {
4: {
5: {
}
}
},
100: {
}
}
},
6: {
7: {
8: {
}
},
14:{
}
},
11: {
12: {
},
13:{
}
}
}
console.log(obj.hasOwnProperty(1)); // true
console.log(obj.hasOwnProperty(6)); // true
console.log(obj.hasOwnProperty(2)); // false
console.log(obj.hasOwnProperty(3)); // false
I want to get true results when I search with 2(others).
What should I do?