C++ IF statements

C++ IF statements

Assessment

Quiz

Computers

8th - 12th Grade

Hard

Created by

Anna Niewodniczanska

Used 128+ times

FREE Resource

Student preview

quiz-placeholder

14 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What does the following code fragment write to the monitor?

Under
Over
Under the limit
Over the limit

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What does the following code fragment write to the monitor?

Under
Over
Under the limit
Over the limit

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

 Evaluate (to true or false) each of the following expressions:
14 >= 14
15 > 15
16 != 16
18 >= 19
T, F, F, F
T, T, T, T
F, T, F, F
F, T, T, F

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Fill in the blank so people 18 years and older are told to vote. if ( age _________ 18 ) cout<<"too young!"; else cout<<"GO VOTE!";

>
>=
<=
<

5.

MULTIPLE CHOICE QUESTION

5 mins • 1 pt

How many choices are possible when using a single if-else statement?
1
2
3
4

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Evaluate the following expression:
2 + 2 == 4
true
false
sometimes true
only true on sundays

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which expression below would determine if a number was odd?
number % 2 ==0
number / 2 == 0
number % 2 == 1
number % 10 == number

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?