Skip to content
Related Articles

Related Articles

C | Misc | Question 7
  • Difficulty Level : Basic
  • Last Updated : 18 Jan, 2014
GeeksforGeeks - Summer Carnival Banner




#include <stdio.h>
int main()
{
    int a[][3] = {1, 2, 3, 4, 5, 6};
    int (*ptr)[3] = a;
    printf("%d %d ", (*ptr)[1], (*ptr)[2]);
    ++ptr;
    printf("%d %d\n", (*ptr)[1], (*ptr)[2]);
    return 0;
}

(A) 2 3 5 6
(B) 2 3 4 5
(C) 4 5 0 0
(D) none of the above


Answer: (A)

Explanation:

Quiz of this Question

Want to learn from the best curated videos and practice problems, check out the C Foundation Course for Basic to Advanced C.
My Personal Notes arrow_drop_up
Recommended Articles
Page :