start()
printf()
main()
getch()
Assignment Relational Arithmetic
Arithmetic Relational Assignment
Relational Arithmetic Assignment
Assignment Arithmetic Relational
auto
case
main
default
float
double
long double
far double
2
4
1
Depends on the system
_infomax
3infomax
infomax_ica
infomax123
What will be output if you will compile and execute the following c code?
int main(){ int a=5; float b; printf("%d",sizeof(++a+b)); printf(" %d",a); return 0;}
2 6
4 6
2 5
4 5
print("Hello World");
echo("Hello World");
printf("Hello World");
None of these
2 bytes
4 bytes
8 bytes
1 byte
The basic data type of C
Qualifier
Short is the qualifier and int is the basic data type
All of the mentioned
What is the output of this statement
printf("%d", (a++));
The value of (a + 1)
Error message
Garbage
The current value of a
3
int my_num = 100,000;
int my_num = 100000;
int my num = 1000;
int $my_num = 10000;
Keywords can be used as variable names
Variable names can contain digits
Variable names do not contain blank spaces
Capital letters can be used in variable names.
When the following piece of code is executed, what happens?
b = 3;a = b++;
a contains 3 and b contains 4
a contains 4 and b contains 4
a contains 4 and b contains 3
a contains 3 and b contains 3
AT & Ts Bell Laboratories of USA in 1972
AT & Ts Bell Laboratories of USA in 1970
Sun Microsystems in 1973
Cambridge University in 1972
Addition, Division, Modulus
Addition, Modulus, Division
Multiplication, Substration, Modulus
Modulus, Multiplication, Substration
What will be the output of the following code?
int x = 5;printf("%d", ++x);
5
6
7
volatile
true
friend
export
char
array
immutable
mutable
const
What is the output of the following code?
int a = 5;printf("%d", a == 5);
0
Undefined
scanf()
getche()
gets()
int num;
integer num;
num int;
num integer;
Bjarne Stroustrup
James A. Gosling
Dennis Ritchie
Dr. E.F. Codd
&&
| |
!
All of the above
What will be output if you compile and execute the following ‘C’ code?
void main(){int i=4,x;x=++i + ++i + ++i;printf("%d",x);}
21
18
19
Compilation error
getchar()
cin.get()
Compiler
Interpreter
Assembler
None of These
int main(){int x,y,z;x='1'-'0'; /* line-1 */y='a'-'b'; /* line-2 */z=x+y;printf("%d",z);}
Error because of incorrect line-1 only.
Error because of incorrect line-1 and line-2.
Error because of incorrect line-2 only.
Spaces
Digits
Underscores
Letters
main(){ int a, b; a=b=4; b=a++; printf("%d %d %d %d", a++, --b, ++a, b--);}
5 3 7 3
Syntax error
5 4 5 3
6 2 6 4
void
endl
switch
*
&
%
#
link, load, code, compile and execute
code, compile, link, execute and load
code, compile, link, load and execute
compile, code, link, load and execute
System programming language
General purpose language
Data processing language
None of the above
+
++
30
32
36
40
world
addition23
test-name
factorial
10
20
None
float, double
short int, double, long int
float, double, long double
double, long int, float
An Editor
A compiler
An operating system
infomax
info_max
info max
All of these
real
int
char > int > float
int > char > float
char < int < double
double > char > int
||
//
/
/*
A
B
ADA
C++
results in a syntax error
output Infomax7
outputs garbage
outputs infomax and terminates abruptly