61.
What will be the output of the following C code (if run with no options or arguments)?
#include <stdio.h>
int main(int argc, char *argv[])
{
    printf("%d\n", argc);
    return 0;
}

62.
Comment on the following C statement.
const int *ptr;

63.
What will be the output of the following C code?
#include <stdio.h>
void main()
{
    char a[10][5] = {"hi", "hello", "fellows"};
    printf("%p\n", a);
    printf("%p", a[0]);
}

65.
What will be the output of the following C code?
#include <stdio.h>
void f(int a[2][])
{
    a[0][1] = 3;
    int i = 0, j = 0;
    for (i = 0;i < 2; i++)
    for (j = 0;j < 3; j++)
    printf("%d", a[i][j]);
}
void main()
{
    int a[2][3] = {0};
    f(a);
}

66.
What will be the output of the following C code?
#include <stdio.h>
int mul(int a, int b, int c)
{
    return a * b * c;
}
void main()
{
    int *function_pointer;
    function_pointer = mul;
    printf("The product of three numbers is:%d",
    function_pointer(2, 3, 4));
}

67.
What will be the output of the following C code?
#include <stdio.h>
int main()
{
    int ary[4] = {1, 2, 3, 4};
    int *p = ary + 3;
    printf("%d\n", p[-2]);
}

68.
What will be the output of the following C code?
#include <stdio.h>
int x = 0;
void main()
{
    int *ptr = &x;
    printf("%p\n", ptr);
    x++;
    printf("%p\n ", ptr);
}

70.
What will be the output of the following C code?
#include <stdio.h>
struct student
{
    int no = 5;
    char name[20];
};
void main()
{
    struct student s;
    s.no = 8;
    printf("hello");
}

Read More Section(Pointer)

Each Section contains maximum 100 MCQs question on Pointer. To get more questions visit other sections.