JavaScript

JavaScript syntax, DOM, ES6+, async patterns, and web interactivity.

01

Quizzes

10

Questions

00

eBooks

00

Articles

00

Likes

12

Views

00

Shares

JavaScript

QUESTION NO 01
Share
Which keyword declares a block-scoped variable?

Answer: let
let (and const) are block-scoped; var is function-scoped.
302 Quizzes
2930 Questions
00 Likes
QUESTION NO 02
Share
JavaScript is primarily used for?

Answer: Making web pages interactive
JS adds behavior and interactivity in browsers (and servers via Node).
302 Quizzes
2930 Questions
00 Likes
QUESTION NO 03
Share
=== compares?

Answer: Value and type
Strict equality checks type and value without coercion.
302 Quizzes
2930 Questions
00 Likes
QUESTION NO 04
Share
typeof null returns?

Answer: "object"
A long-standing JS quirk: typeof null === "object".
302 Quizzes
2930 Questions
00 Likes
QUESTION NO 05
Share
Array method that creates a new array by transforming each item?

Answer: map
map returns a new array of mapped values.
302 Quizzes
2930 Questions
00 Likes
QUESTION NO 06
Share
JSON stands for?

Answer: JavaScript Object Notation
JSON is a text format based on JS object syntax for data interchange.
302 Quizzes
2930 Questions
00 Likes
QUESTION NO 07
Share
A Promise represents?

Answer: A future completion/failure of an async operation
Promises handle asynchronous success (resolve) or failure (reject).
302 Quizzes
2930 Questions
00 Likes
QUESTION NO 08
Share
addEventListener is used to?

Answer: Attach event handlers to elements
It registers callbacks for events like click, submit, keydown.
302 Quizzes
2930 Questions
00 Likes
QUESTION NO 09
Share
const prevents?

Answer: Reassignment of the binding
const forbids reassigning the variable; object contents may still change.
302 Quizzes
2930 Questions
00 Likes
QUESTION NO 10
Share
NaN stands for?

Answer: Not a Number
NaN is the result of invalid numeric operations; typeof NaN is "number".
302 Quizzes
2930 Questions
00 Likes