Data type of an address i.e. value of pointer variable is always ______.

Each statement below has blank space to fit one of the word(s) or phrase(s) in the
list below. Enter your choice in the “tear-off” answer sheet attached to the
question paper, following instructions there in.

A. int B. sizeof C. character
D. global E. long F. double
G. unsigned int H. while I. goto
J. static K. string L. auto
M. structure N. break O. do…while

4.1 ______ is unconditional jump statement in C.
4.2 ______ variable is initialized only once at compile time.
4.3 ‘2’ is an example of ______ constant.
4.4 Data type of an address i.e. value of pointer variable is always ______.
4.5 ______ loop requires a semicolon (;) at the end.
4.6 ______ is an operator as well as a keyword in C.
4.7 ______ is the default storage class of any declared variable.
4.8 ______ always ends with a null character.
4.9 By default any user-defined function returns ______ type of data.
4.10 ftell( ) function returns ______ type of data.

In for loop, the body of loop contains only a semicolon is valid in C.

Each statement below is either TRUE or FALSE. Choose the most appropriate
one and ENTER in the “tear-off” sheet attached to the question paper, following
instructions therein.
2.1 Linker converts source program into machine code.
2.2 In for loop, the body of loop contains only a semicolon is valid in C.
2.3 main( ) is a library function defined in stdio.h file.
2.4 Floating point operand cannot be used with modulo operator.
2.5 C performs bound checking for array.
2.6 In C, every function must have return statement.
2.7 scanf( ) function cannot input character array with space.
2.8 Two pointer variables cannot be added or multiplied.
2.9 Only one character pointer is sufficient to store string containing 50 characters.
2.10 Return type of fseek( ) function is integer.

What will be the output of the following code?

1.10 What will be the output of the following code?
struct abc { int a;
int b; } v[3], *p;
main() { p=v; p->a=3;
p->b=p->a;
printf (“%d %d”,v[0].a, v[0].b); }
A) 3 4
B) 4 3
C) Any garbage values
D) 3 3

What will be the output of the following code?

1.9 What will be the output of the following code?
void fun(int a[ ], int s)
{ a[0]=a[2]+a[2]; a[2]=a[0]+a[0];
a[1]=a[1]+s, a[3]=a[3]*a[3]; }
main() { int n[ ]={5,3,2,1}, size=4;
fun(n, size);
printf(“%d %d %d %d”, *n, n[1], n[2], n[3]); }
A) 5 3 2 1
B) Syntax error
C) 5 7 8 1
D) 4 7 8 1

What is the output of the following code?

1.8 What is the output of the following code?
main()
{ int a=1, b=10;
swap(a, b);
printf(“\n %d %d”, a, b);
}
swap(int x, int y)
{ int temp;
temp = x;
x = y;
y = temp;
}
A) 1 1
B) 1 10
C) 10 1
D) None of the above

What is the output of the following code?

1.6 What is the output of the following code?
main()
{
int n[3] [3] = {2, 4, 3
6, 8, 5,
3, 5, 1};
int *ptr;
ptr=n;
printf(“%u”, n[2]);
printf(“%u”, ptr[2]);
printf(“%u”, * (ptr+2));
A) 4 8 5
B) 4 1 6 3 3
C) 3 5 1 4 8 5 2 6 3
D) None of the above

What is the effect of the following code?

1.5 What is the effect of the following code?
main() { int option=4;
switch(option/2)
{ case 1: printf(“EAST ”);
case 2: printf(“WEST ”);
case 3: printf(“NORTH ”);
case 4: printf(“SOUTH ”); } }
A) WEST
B) Syntax error because break is missing
C) WEST NORTH SOUTH
D) Syntax error because default case is missing