5 votes 5 votes What will be the output of the following program? #include<stdio.h> main() { int a[2][3][4]; printf("%d", a[1][0]-a[0][2]); } Programming in C goclasses_wq6 goclasses programming programming-in-c array output numerical-answers 2-marks + – GO Classes asked Apr 6, 2022 retagged Apr 26, 2022 by Lakshman Bhaiya GO Classes 531 views answer comment Share Follow See all 0 reply Please log in or register to add a comment.
9 votes 9 votes Answer: 4 a[1][0] is a pointer to integer at a[1][0][0] and a[0][2] is a pointer to integer at a[0][2][0] Their difference is number of integers between two indexes between them i.e. 4. Shoto answered Apr 7, 2022 edited Sep 17, 2022 by Shoto Shoto comment Share Follow See 1 comment See all 1 1 comment reply Harshad_Shinde commented Sep 17, 2022 reply Follow Share You have made wrong diagram. As in each 2D array there are only 3 rows and you have drawn 4. …..a[2][3][4] 1 votes 1 votes Please log in or register to add a comment.