NEW
Font size
WorksheetsBasics Of C Programming
Total questions: 10
Worksheet time: 5mins
Which header file can be used to define input/output function prototypes and macros?
- math.h
- memory.h
- stdio.h
- dos.h
The correct order of evaluation for the expression “z = x + y * z / 4 % 2 – 1”
* / % = + -
/ * % - + =
- + = * % /
* / % + - =
How many times CppBuzz.com is printed?
int main()
{
int a = 0;
while(a++);
{
printf("CppBuzz.com");
}
return 0;
}
0 time
1 time
Compilation Error
Infinite times
How many times CppBuzz.com is printed on console?
int main()
{
int a = 0;
while(a++)
{
printf("CppBuzz.com");
}
return 0;
}
Nothing is printed on screen
0 time
1 time
Infinite times (Untill Stack overflow)
What is output of below program?
int main()
{
int i,j,count;
count=0;
for(i=0; i<5; i++);
{
for(j=0;j<5;j++);
{
count++;
}
}
printf("%d",count);
return 0;
}
55
54
1
0
What is output of below program?
int main()
{
int i;
for(i=0; i<5; ++i++)
{
printf("Hello");
}
return 0;
}
Hello is printed 5 times
Compilation Error
Hello is printed 2 times
Hello is printed 3 times
What is an Identifier in C Language.?
Name of a Function or Variable
Name of a Macros
Name of Structure or Union
All the above.
Find an integer constant.
3.145
34
"125"
None of the above
Number of Keywords present in C Language are .?
32
34
62
64
Each statement in a C program should end with.?
Semicolon ;
Colon :
Period . (dot symbol)
None of the above.
