&
&&
||
!
Moves the file pointer to a specific location
Reads a file
Writes to a file
Closes a file
-5
1
0
+5
What will be the output of the following code?
int a = 10, b = 20;printf("%d", a + b);
30
1020
10+20
Compiler error
for (int i = 0; i < 10; i++)
for i = 0 to 10 step 1
for (i = 0; i < 10; i++)
for (i < 10; i++)
-3.4e38 to 3.4e38
-32767 to 32768
-32668 to 32667
-32768 to 32767
What is the output of the following code?
int a = 5;printf("%d", a == 5);
5
Undefined
int my_num = 100,000;
int my_num = 100000;
int my num = 1000;
int $my_num = 10000;
10
20
None
Algorithm
Flow-Charts
Procedural
Object Oriented
The dog barked.
The cat chased the mouse.
The dog barked because it was hungry.
The cat chased the mouse, and the mouse ran away.
An array of characters
The object of some class
Same as other primitive data type
Linkedlist of characters
Call by reference
Call by value
Call by reference by passing base address to a function
Both A and C
Please close the door.
It is drizzling outside.
Is the food ready?
He is not here yet.
4 Bytes
8 Bytes
Depends on the system/compiler
Cannot be determined
1return
return1
return
$return_1
Keywords can be used as variable names
Variable names can contain digits
Variable names do not contain blank spaces
Capital letters can be used in variable names.
32
36
40
break
exit(0)
abort()
All of the mentioned
float
real
int
double
long double
far double
What will be the output of following program?
int main() { for(int c=1;c<5;++c); printf(“%d”,c); }
6
12345
To exit the function and return control to the calling function
To pause the function temporarily
To call the function again
To exit the program
int arr[5] = {1, 2, 3, 4, 5};printf("%d", arr[3]);
2
3
4
What will be the output of the following program?
int main() { int x=5; printf(“%d %d %d”,x,x<<2,x>>2); }
1 20 5
5 1 20
5 20 1
20 1 5
print()
scanf()
input()
All of the above
-1
Big a house
A house big
House big a
A big house
getchar()
gets()
cin.get()
continue
None of these
What is the output of this statement
printf("%d", (a++));
The value of (a + 1)
Error message
Garbage
The current value of a
ceil(1.66)
floor(1.66)
roundup(1.66)
roundto(1.66)
printf("\n");
echo '\n';
printf('\n');
printf('\\n')
was doing
did
will do
have done
N=m=0
Value+=10
mySize=x<y?9:11
Value=+=10
power of y to the x
power of x to the y
logarithm of x on the base y
Such function does not exist
Nested structure
Recursive structure
Union structure
Inline structure
Id_No
ID_NO
IdNo
Id No
What will be output if you compile and execute the following ‘C’ code?
void main(){int i=4,x;x=++i + ++i + ++i;printf("%d",x);}
21
18
19
Compilation error
Program will terminate with an error
Undefined behavior
Array index will wrap around
stdio.h
conio.h
stdlib.h
An Editor
A compiler
An operating system
//
/
#
/*
Assignment Relational Arithmetic
Arithmetic Relational Assignment
Relational Arithmetic Assignment
Assignment Arithmetic Relational
print("Hello World");
echo("Hello World");
printf("Hello World");
for loop
while loop
do-while loop
none of the above
include
char
Read
Write
Execute
Copy
Decimal
Binary
Octal
Hexadecimal
What is the final value of x when the code is executed?
int x; for(x=0; x<10; x++) {}
9