Page 60 - Modular_V2.0_C++_Flikpbook
P. 60
10. ............................ statements are also known as decision making statements.
a. Assignment b. Conditional
c. Addition d. None of these
B. Fill in the blanks.
1. It is necessary to terminate each statement of a program by putting the ............................ at
the end.
2. When a variable is declared, some space is reserved for it in the ............................ of the computer.
3. The ............................ Operator is used to check whether the values of two operands are equal.
4. Cout is part of the ............................ class.
5. The ............................ is used to start the body of the main( ) function.
6. …………………… can be used inside the switch body but cannot be used inside if body.
C. Write ‘T’ for true and ‘F’ for false.
1. The getch( ) function keeps the output screen open. .....................
2. Equal to sign is used to assign a value to a variable. .....................
3. Logical operators are used to combine more than one relational expression. .....................
4. The /* and */ symbols are used to add multiline comment. .....................
5. Explicit typecasting is done automatically by the C++ compiler. .....................
6. We cannot use floating-point value in the switch statement. .....................
Section B
A. Short answer type questions.
1. What is the use of #include<iostream.h> statement in a C++ program?
2. Write the syntax to declare a variable.
3. What is the difference between ‘/’ and ‘%’ operators?
4. What is the difference between \\ and // symbols?
5. Define the if…else statement.
6. Can ternary operator replace the if…else statement?
B. Long answer type questions.
1. Write any four variable naming conventions.
2. What is the difference between *= and /= operators?
3. What is the difference between compiling a program and running a program?
4. What is difference between cout and cin objects?
5. Write a C++ program to accept a number between 1 to 7 and print the day of week according
to the entered number.
6. What is the purpose of default clause in a switch statement?
58
Touchpad MODULAR (Ver. 2.0)

