Professional Documents
Culture Documents
SECTION A
(b) Write a program to arrange the given set of numbers in ascending order using
pointer.
(b) When do you use a virtual function? Explain with suitable example
(b) Write a program to perform complex number arithmetic operations using operator
overloading
b) Create a class MAT of size m x n. Define all possible matrix operations for MAT
type objects
7 (a) What is a friend function? What are the merits and demerit of using friend
function?
(b) Illustrate with an example, how the endl and setw manipulator works?
SECTION B
SECTION C
Question No: 1
&
&&
|
|&
Question No: 2
How long does this loop run: for(int x=0; x=3; x++)
Never
Three times
Forever
None of above
Question No: 3
while
until
do
4. if
Question No: 4
break
goto
exit
switch
Question No: 5
break
goto
exit
switch
Question No: 6
The difference between while structure and do structure for looping is--
Question No: 7
Question No: 8
Question No: 9
int
long int
short int
float
Question No: 10
What punctuation is used to signal the beginning and end of code blocks?
{ }
-> and <-
BEGIN and END
( and )
Question No: 11
Mutable
Default
Readable
Volatile
Question No: 12
Global variables are declared in a separate file and accessible from any program.
Local variables are declared inside a function and accessible within the function
only.
Global variables are declared inside a function and accessible from anywhere in
program
Local variables are declared in the main body of the program and accessible only
from functions.
Question No: 13
Question No: 14
c++;
c = c + 1;
c + 1 => c;
c += 1
Question No: 15
b = 3;
a = b++;
Question No: 17
==
=>
>=
>=
Question No: 18
What is the final value of x when the code int x; for(x=0; x<10; x++) {} is run?
10
9
0
1
Question No: 19
Question No: 20
for
do while
while
repeat until
Question No: 21
0
Infinitely
1
Variable
Question No: 22
. (dot)
; (semi-colon)
: (colon)
(single quote)
Question No: 23
*/ Comments */
** Comment **
/* Comment */
{Comment}
Question No: 24
float
real
int
double
Question No: 25
:=
=
equal
==
Question No: 26
A variable is/are--
Question No: 27
Question No: 28
papername
writername
typename
printname
Question No: 29
bitand
bittand
bittand
band
Question No: 30
The first one refers to a variable whose identifier is x and the second one refers
to the character constant x
The first one is a character constant x and second one is the string literal x
Both are same
None of above
Question No: 31
v
f
w
Question No: 32
Question No: 33
There is a unique function in C++ program by which all C++ programs start their
execution--
Start()
Begin()
Main()
Output()
Question No: 34
Parameters
Parenthesis
Curly braces
None of these
Question No: 35
Question No: 36
Question No: 37
Question No: 38