View all questions & answers for the JavaScript-Developer-I exam
Refer to the followingarray:
Let arr = [1, 2, 3, 4, 5];
Which three options result in x evaluating as [1,2]?
Choose 3 answer
let x = arr. slice (2);
let x = arr. slice (0, 2);
let x arr.filter((a) => (return a <= 2 });
let x = arr.filter ((a) => 2 }) ;
let x=arr.splice(0, 2);
Submit