1.

What will be the output of the following C code?
#include <stdio.h>
int main()
{
int A[5] = {10, 20, 30, 40, 50};
int *ptr = A + 2;
printf("%d %d n", ptr[-1], A[*ptr]);
}

A. 20 0
B. Compilation Error
C. 20 Garbage value
D. 0 20
E. None of these
Answer» B. Compilation Error


Discussion

No Comment Found