to go to the next iteration in a loop
come out of a loop
exit and return to the main function
restarts iterations from beginning of loop
D. restarts iterations from beginning of loop
True
False
string.h
strings.h
text.h
strcmp.h
True
False
the logical operator && cannot be used in a test condition
the while loop is an exit-condition loop
the test condition is always true
the test condition is always false
abstract
Virtual
Dynamic
Typeid
True
False
main()
{
int sub[50];
for(i=0; i<=48;i++)
{
sub[i]=i;
printf("
%d", sub[i]);
}
}
0 to 48 will be displayed
48
49
Compilation Error
True
False
the question mark should be an equal sign
the first semicolon should be a colon
there are too many variables in the statement
the conditional operator is only used with apstrings
void main()
{
int z, a = 5, b = 3; z = a * 2 + 26 % 3;
printf("%d", z); }
10
0
12
None of the above
''
" "
'a'
abc'
True
False
main()
{
unsigned int a = 10;
while (a>=10)
{
int a; a-- ;
}
printf("%i", a);
}
Infinite loop
9
0
None
24
2
26
None
4
2
8
10
What will be output if you will compile and execute the following c code?
#include
#define x 5+2
int main(){
int i;
i=x*x*x;
printf("%d",i);
return 0;
}
27
343
233
Compiler Error
True
False
True
False
#if
#elseif
#undef
#pragma
True
False
void main()
{
int a = 0;
while (a<=50) for(;;) if(++a % 50==0) break;
printf("a = %d", a);
}
a = 100
a = 50
compilation error
runtime error
main()
{
xyz: goto abc;
printf("Hello");
abc: printf("World");
goto xyz;
}
Infinite loop
Hello World
World Hello
Compilation error
Statically typed language
Dynamically typed language
Both Statically and dynamically typed language
Type-less language
for
while
do-while
while & do-while
main()
{
int a = 5, b = 6;
(a == b? printf("%d", a));
}
0
5
Error
None of the above
True
False
True
False
A
B
BCPL
C++
3
4
5
infinite
the return 0; statement
the first statement after the loop
the statement following the continue statement
the next iteration of the loop