C Language MCQ - English
What is (void*)0?
Answer : A
View More Related Question
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?
2) What will be the output of the program If the integer is 4bytes long? #include<stdio.h>
int main()
{
int ***r, **q, *p, i=8;
p = &i;
q = &p;
r = &q;
printf("%d, %d, %d\n", *p, **q, ***r);
return 0;
}
3) What will be the output of the following C code? #include <stdio.h>
void main()
{
int x = 0;
int *ptr = &5;
printf("%p\n", ptr);
}
4) What would be the equivalent pointer expression for referring the array element a[i][j][k][l]
5) What will be the output of the following C code? #include <stdio.h> int *f();
int main()
{
int *p = f();
printf("%d\n", *p);
}
int *f()
{
int *j = (int*)malloc(sizeof(int));
*j = 10;
return j;
}
View Answer