An Editor
A compiler
An operating system
None of these
exit
break
continue
return
main function arguments
main arguments
Command-Line arguments
Parameterized arguments
put together the file and functions that are required by the program
translate the instructions into a form suitable for execution by the program
load the executable code into the memory and execute them
allow the user to type the program
It breaks out of both loops.
It only breaks out of the innermost loop.
It causes a compile-time error.
It stops the program.
N=m=0
Value+=10
mySize=x<y?9:11
Value=+=10
fclose()
closefile()
fileclose()
endfile()
float
double
long double
far double
char
int
Input data
The program does not require any function.
Output data
The program must have at least one function.
Logical Operator
Conditional Operator
typecast
Ternary
float_int, keyword, A1
ANSI, ascii, cpu
valid, variable, name
None of the above
1
2
4
8
"r"
"w"
"rw"
"read"
for (int i = 0; i < 10; i++)
for i = 0 to 10 step 1
for (i = 0; i < 10; i++)
for (i < 10; i++)
“programming Trick”
“programming"
‘programming'
$ programming $
scanf()
getch()
getche()
gets()
function(int ptr);
function(int *ptr);
function(*ptr);
function(ptr *int);
What will the following code print?
int x = 5;if (x = 0)printf("Zero");elseprintf("Not zero");
Zero
Not zero
Compilation error
Error
immutable
mutable
const
volatile
What is the output of the following code?
int arr[5] = {1, 2, 3, 4, 5};printf("%d", arr[3]);
3
print("Hello World");
echo("Hello World");
printf("Hello World");
Nested structure
Recursive structure
Union structure
Inline structure
printf("\n");
echo '\n';
printf('\n');
printf('\\n')
-4
-2.8
+2.8
+3
10
20
0
None
int num;
integer num;
num int;
num integer;
ctype.h
stdio.h
conio.h
math.h
Depends on the system
results in a syntax error
output Infomax7
outputs garbage
outputs infomax and terminates abruptly
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
_infomax
3infomax
infomax_ica
infomax123
getchar()
cin.get()
5
6
Undefined
arr[2]
arr(2)
arr[3]
arr[1]
Consider the following code and How many bytes of memory will be allocated?
int *ptr = (int *)malloc(10 * sizeof(int));
10 bytes
20 bytes
80 bytes
40 bytes
start()
printf()
main()
for loop
while loop
do-while loop
ceil(1.66)
floor(1.66)
roundup(1.66)
roundto(1.66)
What will be the output of the following code segment?
int x = 24, y = 39, z = 45;z = x + y;y = z - y;x = z - y;printf("\n%d %d %d", x, y, z);
24 39 63
39 24 63
24 39 45
39 24 45
The basic data type of C
Qualifier
Short is the qualifier and int is the basic data type
All of the mentioned
&&
| |
!
All of the above
exit(0)
abort()
Either True or False
is less than or is more than
is equal or less or more
An array of characters
The object of some class
Same as other primitive data type
Linkedlist of characters
16
It is used to define global variables
It is used to define a macro
It is used to include standard or user-defined header files in the program
It is used to include comments in the code
include
Constants
Keywords
Operators
Tokens