2.
Consider the array below. What will be the output of the find() method?
const numbers = [50, 60, 80, 120, 200];
const result = numbers.find(num => num > 100);
console.log(result);
undefined
120, 200
120
80
Correct: C
The find() method in JavaScript returns the first element from an array that fulfills the condition provided. In this case, the condition is num => num > 100, which means the first number bigger than 100. Looking at the array, the first number that meets this condition is 120. So, 120 will be the output.