Q
Which keyword is used to create a new instance of an object?

Answer & Solution

Answer: Option A
Solution:
The 'new' keyword is used to create a new instance of an object or a user-defined constructor function.
Related Questions on Average

Which keyword is used to create a loop with multiple cases in JavaScript?

A). switch

B). for

C). while

D). if

Which keyword is used to remove a property from an object?

A). delete

B). remove

C). erase

D). discard

What does the 'this' keyword refer to in JavaScript?

A). The object on which a method is called

B). The global object

C). The parent function

D). The current file

What does the 'return' keyword do in JavaScript?

A). Exits a loop or switch statement

B). Continues to the next iteration in a loop

C). Returns a value from a function

D). Skips the current iteration in a loop

What does the 'break' keyword do in JavaScript?

A). Exits a loop or switch statement

B). Continues to the next iteration in a loop

C). Returns a value from a function

D). Skips the current iteration in a loop

Which keyword is used to declare constants in JavaScript?

A). const

B). let

C). var

D). constant

What is the purpose of the 'if' keyword in JavaScript?

A). To perform conditional execution

B). To declare functions

C). To create loops

D). To skip iterations in a loop

What does the 'typeof' keyword return for a number?

A). number

B). string

C). object

D). undefined

What is the purpose of the 'let' keyword in JavaScript?

A). To declare constants

B). To declare block-scoped variables

C). To declare functions

D). To perform logical operations

Which keyword is used to create an instance of an array in JavaScript?

A). new

B). instanceof

C). this

D). create