wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

C++ Reviewer

Total questions: 15

Worksheet time: 8mins

Name
Class
Date
1.

The filename sample1.cpp, cpp means C plus plus

a)
True
b)
False
2.

The value of pi=3.1416 can be changed when it is included in a C++ program.

a)
True
b)
False
3.

A variable declared as int is representing any positive or negative whole number.

a)
True
b)
False
4.

Assembly Language is the 2nd generation language and easier to understand than a machine language.

a)
True
b)
False
5.

The data types, "float" and "double" are used to declare decimal numbers.

a)
True
b)
False
6.

Who is the developer of C++?

a)

Blaise Pascal

b)

Steve Jobs

c)

Bill Gates

d)

Bjarne Stroustrup

7.

Complete the meaning of IDE: Integrated _______ Environment

a)

Development

b)

Developer

c)

Decision

d)

Divisible

8.

The application we use in coding a C++ program.

a)

Notepad++

b)

Code: :Blocks

c)

Notepad

d)

Online C++ compiler

9.

#include <iostream> is a part of C++ program

a)

Comment

b)

Namespace Declaration

c)

Preprocessor Directives

d)

Function Definitions

10.

return 0; at the bottom part of C++ program, means that

a)

that the output of the program is zero

b)

that the program has errors

c)

that the program run successfully

d)

that no compilation will happen

11.

       int x = 8, y = 2;

int result = x + y * 3; 

       cout << result;

a)

41

b)

30

c)

14

d)

13

12.

      int age = 11;

bool canVote = (age > 10) && (age <= 18);

a)

0 (false)

b)

1 (true)

13.

.  int c = 12, d = 5; 

       int result = c / d + c % d; 

       cout << result;

a)

4

b)

5

c)

2.40

d)

2.5

14.

Which is a valid variable?

a)

Gen_Ave

b)

5genAve

c)

Gen/Ave

d)

5678

15.

Which is NOT a reserved keyword in C++?

a)

and

b)

case

c)

break

d)

score