1.
If a variable is a pointer to a structure, then which of the following operator is used to access data members of the structure through the pointer variable?
A. 
B. 
C. 
D. 
2.
What will be the output of the program ?
int main()
{
inti=3, *j, k;
j = &i;
printf("%d\n", i**j*i+*j);
return0;
}
A. 
B. 
C. 
D. 
3.
What will be the output of the program ?
int main()
{
void *vp;
char ch=74, *cp="JACK";
int j=65;
vp=&ch;
printf("%c", *(char*)vp);
vp=&j;
printf("%c", *(int*)vp);
vp=cp;
printf("%s", (char*)vp+2);
return 0;
}
A. 
B. 
C. 
D. 
4.
What will be the output of the program ?
int main()
{
inti, a[] = {2, 4, 6, 8, 10};
change(a, 5);
for(i=0; i<=4; i++)
printf("%d, ", a[i]);
return 0;
}
change(int *b, int n)
{
int i;
for(i=0; i<n; i++)
*(b+1) = *(b+i)+5;
}
A. 
B. 
C. 
D. 
5.
What will be the output of the program ?
int main()
{
char *str;
str = "%s";
printf(str, "K\n");
return 0;
}
A. 
B. 
C. 
D. 
6.
Which of the following function is used to find the first occurrence of a given string in another string?
A. 
B. 
C. 
D. 
7.
What will be the output of the program ?
int main()
{
char p[] = "%d\n";
p[1] = 'c';
printf(p, 65);
return 0;
}
A. 
B. 
C. 
D. 
8.
Trace the output.
int main()
{
char str[] = "basic";
char *s = str;
printf("%s ", s++ +3);
printf("%s",s);
return 0;
}
A. 
B. 
C. 
D. 
9.
What would be the equivalent pointer expression for referring the array element a[i][j][k][l]
A. 
B. 
C. 
D. 
10.
What will be the output of the program ?
int main()
{
int i;
char a[] = "\0";
if(printf("%s", a))
printf("The string is empty\n");
else
printf("The string is not empty\n");
return 0;
}
A. 
B. 
C. 
D. 
11.
Are the expression *ptr++ and ++*ptr are same?
12.
If the size of integer is 4bytes, What will be the output of the program?
int main()
{
int arr[] = {12, 13, 14, 15, 16};
printf("%d, %d, %d\n", sizeof(arr), sizeof(*arr), sizeof(arr[0]));
return 0;
}
A. 
B. 
C. 
D. 
13.
What will be the output of the program ?
int main()
{
char str[] = "India\0\is Best\0";
printf("%d\n", strlen(str));
return 0;
}
A. 
B. 
C. 
D. 
14.
What will be the output of the program ?
int main()
{
printf(5+"Good Morning\n");
return 0;
}
A. 
B. 
C. 
D. 
15.
What will be the output of the program ?
int main()
{
char str1[] = "Hello";
char str2[] = "Hello";
if(str1 == str2)
printf("Equal\n");
else
printf("Unequal\n");
return 0;
}
A. 
B. 
C. 
D.