wayground logo

Free Printable Worksheets

NEW

Font size

S
M
L
XL
Worksheets

node Js/Javascript Quizz

Total questions: 14

Worksheet time: 7mins

Name
Class
Date
1.

In web development, what is a framework?

a)


A tool we use to design GUIs (Graphical user interfaces)

b)

A cloud tool used to host websites

c)

A place for developers to collaborate and work asynchronously

d)

A software designed to support the development of web applications including web services, web resources, and web APIs

2.

Which of the following code will print "Hello" on the output screen?

a)

print("Hello");

b)

console.log(Hello);

c)

console.log("Hello");

d)

printf("%s","Hello");

3.

What JavaScript Engine is used by Google Chrome?

a)

Y8

b)

Adobe Flash Player

c)

Friv

d)

V8

4.

What is the right syntax for importing a module?

a)

require()

b)

function()

c)

import()

d)

module.import()

5.

What will be the output

var num = 10

console.log(num + 10)

a)

83

b)

20

c)

none of these

d)

1010

6.

What type of variable is quantites?

var quantities = [2, 4, 10, 1]

a)

string

b)

boolean

c)

array

d)

number

7.

What type of variable is apple?

var apple = " Fuji "

a)

boolean

b)

string

c)

array

d)

number

8.

What will this code display

a)

Hello user

b)

Hello Emma

c)

Hello+user

d)

nothing

9.

What will this code display?

a)

570

b)

569

c)

568

d)

attendees

10.

What will be the output of the following code?

var x = 5; var y = 10; console.log(x * y);

a)

50

b)

10

c)

105

d)

15

11.

Which of the following is a valid way to declare a function in JavaScript?

a)

function myFunction[] {}

b)

myFunction() = function {}

c)

function myFunction() {}

d)

function:myFunction() {}

12.

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

a)

The current function

b)

The global object

c)

The parent object

d)

The object that is executing the current function

13.

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

a)

To declare a variable that is function-scoped

b)

To declare a global variable

c)

To declare a constant variable

d)

To declare a variable that is block-scoped

14.

Which of the following methods can be used to convert a string to a number in JavaScript?

a)

parseInt()

b)

toNumber()

c)

convertToNumber()

d)

stringToNumber()