int
float
include
char
final
constant
const
static
float, double
short int, double, long int
float, double, long double
double, long int, float
30
32
36
40
It breaks out of both loops.
It only breaks out of the innermost loop.
It causes a compile-time error.
It stops the program.
What will be the output of the following pseudo code ?
Integer aSet a =4do print a + 2 a = a-1while (a not equals 0)end while
6 6 6 6
6 5 4 3
6 7 8 9
6 8 10 12
Martin Richards
Dennis Ritchie
Ken Thompson
Herman Hellorith
Addition, Division, Modulus
Addition, Modulus, Division
Multiplication, Substration, Modulus
Modulus, Multiplication, Substration
What will be the output of the following code?
int main(){int x,y,z;x='1'-'0'; /* line-1 */y='a'-'b'; /* line-2 */z=x+y;printf("%d",z);}
0
Error because of incorrect line-1 only.
Error because of incorrect line-1 and line-2.
Error because of incorrect line-2 only.
Both can occur multiple times, but a declaration must occur first.
A definition occurs once, but a declaration may occur many times.
Both can occur multiple times, but a definition must occur first.
A declaration occurs once, but a definition may occur many times.
conio.h
string.h
math.h
graphic.h
switch
goto
go back
return
In the following nested conditional statements, which branch will execute?
int x = 4;if (x > 2) { if (x < 5) { printf("x is between 2 and 5"); }} else { printf("x is 2 or less");}
x is between 2 and 5
x is 2 or less
Error
No output
2
4
1
Depends on the system
"r"
"w"
"rw"
"read"
int number;
float rate;
int variable_count;
int $main;
What is the output of the following code?
int a = 5;printf("%d", a == 5);
5
Undefined
auto
case
main
default
Raj says, “He wants ice cream”
Raj had said, “He wants an ice-cream”
Raj will say, “I want an ice-cream”
Raj said, “I want an ice-cream”
immutable
mutable
volatile
is executed only once if the condition is true.
is also known as entry-controlled loop.
is executed at least once if the condition is false.
is unconditional looping statement..
Algorithm
Flow-Charts
Procedural
Object Oriented
* / % + - =
= * / % + -
/ * % - + =
* % / - + =
1return
return1
$return_1
&&
| |
!
All of the above
-3.4e38 to 3.4e38
-32767 to 32768
-32668 to 32667
-32768 to 32767
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
int func();
func() int;
function int func();
declare int func();
double
long double
far double
ctype.h
stdio.h
Id_No
ID_NO
IdNo
Id No
true
friend
export
power of y to the x
power of x to the y
logarithm of x on the base y
Such function does not exist
Continue
break
exit
Big a house
A house big
House big a
A big house
Compilation error
Program will terminate with an error
Undefined behavior
Array index will wrap around
Compiler
Interpreter
Assembler
None of These
void
endl
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
fclose()
closefile()
fileclose()
endfile()
2.5
2.000000
2.500000
Find the output of following code :
int main() { int i=-2; printf (“-i=%d”,-i); return b; }
–i=2
i=-2
–i=-2
–i=+2
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
continue
None of these
ceil(1.66)
floor(1.66)
roundup(1.66)
roundto(1.66)
results in a syntax error
output Infomax7
outputs garbage
outputs infomax and terminates abruptly
signed short
unsigned short
long
strlen()
sizeof()
length()
strlength()
calloc()
malloc()
allocate
New