Home / MCQ Bank / Computer
Computer Pointer Difficulty: Medium

What will be the output of the following C code? #include <stdio.h> void foo( int[] ); int main() { int ary[4] = {1, 2, 3, 4}; foo(ary); printf("%d ", ary[0]); } void foo(int p[4]) { int i = 10; p = &i; printf("%d ", p[0]); }

Select the correct option to test your answer:

More Computer Questions

What is the keyword used for inheritance in C++? Which of these is correct way of inheriting class A by class B? Which element is used for bringing attention? Both the functions randint and uniform accept . . . . . . . . parameters. Polybius square cipher is most closely related to?