Home »
MCQs »
Lodash MCQs
What will be the output of the following code (1) (Lodash)?
8. What will be the output of the following code?
const value = _.range(10);
console.log(value);
- [ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 ,10]
- [1, 2, 3, 4, 5, 6, 7, 8, 9 ,10,11]
- [ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 ]
Answer: C) [ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 ]
Explanation:
The output will be the range from 0 to 9 which makes the total of 10 numbers, therefore [ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 ] will be the output.