Why am I getting inconsistent results instead of 'undefined' when trying to find a non-existent object element in an array?
const arr = [{ id: 1, name: 'Alice' }, { id: 2, name: 'Bob' }, { id: 3, name: 'Charlie' }]
const result = arr.find(item => item.id == 100)
console.log(result)
// Output: { id: 100, name: 'Alice' }