Wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

Programming Review

Total questions: 10

Worksheet time: 5mins

Name
Class
Date
1.

What name is given to a value that can either be true or false?

a)

code

b)

abstract

c)

boolean

d)

logical operator

2.

What JavaScipt function is used to print a statement?

a)

print

b)

println

c)

var

d)

or

3.

When declaring a variable in JavaScript, what key word is needed?

a)

var

b)

println

c)

readln

d)

not

4.

What is missing in the statement below?


var isloggedin=true

a)

" " around the word true

b)

; at the end of the statement

c)

another = before the word true

d)

Capitalized the word VAR

5.

Which of the following is not a logical operator?

a)

AND

b)

OR

c)

NOT

d)

BUT

6.

What symbol is used for the AND operator?

a)

&&

b)

||

c)

|

d)

@@

7.

Which operator is used for the OR operator?

a)

&

b)

!!

c)

||

d)

&&

8.

What is used to represent the NOT operator?

a)

!

b)

!!

c)

&&

d)

||

9.

What does the following statement mean?


var haveSeat=true II haveDesk=true

a)

The student has a chair OR a desk

b)

The student has a chair AND a desk

c)

The student has a chair BUT no desk

d)

The student does not have a desk or a chair

10.

What does the following statement mean?


var hasDog=true && hasCat=false;

a)

The boy has a dog but no cat

b)

The boy has a cat but no dog

c)

The boy has both a dog and a cat

d)

The boy does not have a dog or a cat