Font size
WorksheetsC Language
Total questions: 11
Worksheet time: 6mins
What is the output of this statement "printf("%d", (a++))" ?
The value of (a + 1)
The current value of a
Error message
Garbage
In the C language, the constant is defined _______.
Before main
After main
Anywhere, but starting on a new line.
None of the these.
How many times will the following loop execute?
for(j = 1; j <= 10; j = j-1)
Forever
Never
0
1
Which one of the following is a loop construct that will always be executed once?
for
while
switch
do while
What will the result of len variable after execution of the following statements?
int len;
char str1[] = {"39 march road"};
len = strlen(str1);
11
12
13
14
Which statement can print \n on the screen?
printf("\\n");
printf("n\");
printf("n");
- printf('\n');
C is _______ type of programming language ?
Object Oriented
Procedural
Bit level language
Functional
C language was invented to develop which Operating System?
Android
Linux
Ubuntu
Unix
A pointer is a memory address. Suppose the pointer variable has p address 1000, and that p is declared to have type int*, and an int is 4 bytes long. What address is represented by expression p + 2?
1002
1004
1008
1006
How many bytes does "int = D" use?
0
1
2 or 4
8
What is the maximum number of characters that can be held in the string variable char address line [40]?
38
39
40
41
