ES6+ Features

There are Multiple Choice Questions

Correct answers color: Green

Wrong answers color: Red

 
START LEARNING

#1. Which keyword is block-scoped in JavaScript?

#2. What is the correct syntax for an arrow function?

#3. Which of these is a correct example of destructuring assignment?

#4. How do you declare a default parameter in a function?

#5. What does the spread operator (…) do?

#6. What is a Promise in JavaScript?

#7. What method is used to check if an array includes a specific element?

#8. Which of the following methods is NOT available in ES6+?

#9. What is the purpose of the for…of loop?

#10. How are modules imported in ES6?

#11. What is the nullish coalescing operator (??) used for?

#12. Which ES6+ feature allows iteration over the properties of an object?

#13. What is the output of const x = [1, 2, 3].map((n) => n * 2);?

#14. Which method is used to create a shallow copy of an object?

#15. What is the significance of the super keyword in JavaScript classes?

#16. Which of the following is NOT an ES6+ data structure?

#17. What does the Array.flat() method do?

#18. What is the default value of this in an arrow function?

#19. Which of the following is a new type introduced in ES6+ for large integers?

#20. What is the purpose of the at() method for arrays?

#21. What is the purpose of the Object.fromEntries() method in ES6+?

#22. Which of the following allows for string interpolation in ES6+?

#23. Which statement correctly uses a Set in ES6+?

#24. What does the Array.find() method return?

#25. Which symbol is used for creating private fields in ES6+ classes?

#26. What does the Array.some() method do?

#27. What is the purpose of the Reflect API in ES6+?

#28. What is a tagged template in JavaScript?

#29. How can you handle optional chaining in JavaScript?

#30. Which of these methods creates a new string by padding the original string?

#31. What does Array.from() do?

#32. What is the output of […’hello’] in ES6+?

#33. How do you export multiple variables in ES6+?

#34. What is the difference between Map and WeakMap?

#35. What is the purpose of Array.prototype.flatMap()?

#36. Which of these is a feature of ES6+ classes?

#37. What is the significance of the Symbol type in JavaScript?

#38. What is the output of the following code? javascript Copy code const a = 10; console.log(a ?? 20);

#39. Which of these is a benefit of using default exports?

#40. What does Promise.all() do?

Previous
Finish

Results

Congratulations !

Opps! Try Again

 

For More Information Visit : – India gk

Contact for website Design and development – Chaturbhuja Sons

Leave a Reply