final
constant
const
static
signed short
unsigned short
long
int
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
It returns the size of the variable in bits
It returns the size of the variable in bytes
It returns the size of the variable in kilobytes
It returns the number of elements in an array
Assignment Relational Arithmetic
Arithmetic Relational Assignment
Relational Arithmetic Assignment
Assignment Arithmetic Relational
* / % + - =
= * / % + -
/ * % - + =
* % / - + =
link, load, code, compile and execute
code, compile, link, execute and load
code, compile, link, load and execute
compile, code, link, load and execute
results in a syntax error
output Infomax7
outputs garbage
outputs infomax and terminates abruptly
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.
main function arguments
main arguments
Command-Line arguments
Parameterized arguments
start()
printf()
main()
getch()
Martin Richards
Dennis Ritchie
Ken Thompson
Herman Hellorith
printf("\n");
echo '\n';
printf('\n');
printf('\\n')
_infomax
3infomax
infomax_ica
infomax123
no of students
char
7th
myName
float
include
Logical Operator
Conditional Operator
typecast
Ternary
What is the output of this statement
printf("%d", (a++));
The value of (a + 1)
Error message
Garbage
The current value of a
Either True or False
is less than or is more than
is equal or less or more
All of the above
getchar()
gets()
scanf()
cin.get()
double
array
To determine which operator evaluated first from left to right.
To determine the level of an operator in a program.
To determine how an expression involving more than one operator is evaluated.
To check the expression is valid or not.
10
20
0
None
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);}
Error because of incorrect line-1 only.
Error because of incorrect line-1 and line-2.
Error because of incorrect line-2 only.
“programming Trick”
“programming"
‘programming'
$ programming $
//
/
#
/*
They can contain alphanumeric characters as well as special characters
It is not an error to declare a variable to be one of the keywords(like goto, static)
Variable names cannot start with a digit
Variable can be of any length
2
4
1
Depends on the system
int num;
integer num;
num int;
num integer;
int my_num = 100,000;
int my_num = 100000;
int my num = 1000;
int $my_num = 10000;
Input data
The program does not require any function.
Output data
The program must have at least one function.
Addition, Division, Modulus
Addition, Modulus, Division
Multiplication, Substration, Modulus
Modulus, Multiplication, Substration
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
int x = 5;printf("%d", ++x);
5
6
7
immutable
mutable
volatile
float, double
short int, double, long int
float, double, long double
double, long int, float
2.5
2.000000
2.500000
What is the output of the following code?
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
real
int a = 10, b = 5;printf("%d", a / b);
0.5
15
&&
| |
!
void
endl
switch
8
long double
far double
System programming language
General purpose language
Data processing language
None of the above
*
&
%
Binary operator
Unary operator
Ternary operator
The basic data type of C
Qualifier
Short is the qualifier and int is the basic data type
All of the mentioned
2 bytes
4 bytes
8 bytes
1 byte