wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

WEEK 10 - JAVA

Total questions: 10

Worksheet time: 3mins

Name
Class
Date
1.

It is similar to the conditional statement, but the only difference is this is checks for equality?

a)

Strings

b)

Switch Statement

c)

Character

d)

Enumerators

2.

Using this, a switch or loop statement can be terminated without the complete block of code included inside running?

a)

Case Keyword

b)

Default Keyword

c)

Integers

d)

Break keyword

3.

This keyword ought to be added at the end of the switch statement.

a)

Case Keyword

b)

Default Keyword

c)

Integers

d)

Break keyword

4.

A primitive data type called a ________ represents one of just two possible values.

a)

True or False

b)

Booleans

c)

Switch

d)

If else

5.

It specify a block of codes to be executed, if a specifies condition is true.

a)

Else

b)

If

c)

Else if

d)

Switch

6.

It is used to specify many alternative block of code to be executed.

a)

Else

b)

If

c)

Else if

d)

Switch

7.

This conditional statement used if the same condition is false.

a)

Else

b)

If

c)

Else if

d)

Switch

8.

It is specify a new condition to test, if the first condition is false

a)

Else

b)

If

c)

Else if

d)

Switch

9.

This data type only works with string, char, int and Enums.

a)

Java Switch

b)

Java Booleans

c)

Java If…else

d)

None of the above

10.

It is a form of data that  switch statements can use.

a)

Int

b)

Enum

c)

String

d)

Char