• Courses
  • Tutorials
  • Jobs
  • Practice
  • Contests

UGC-NET | UGC NET CS 2015 Dec - II | Question 16

A three dimensional array in ‘C++’ is declared as int A[x][y][z]. Consider that array elements are stored in row major order and indexing begins from 0. Here, the address of an item at the location A[p][q][r] can be computed as follows (where w is the word length of an integer):

(A)

&A[0][0][0] + w(y * z * q + z * p + r)

(B)

&A[0][0][0] + w(y * z * p + z*q + r)

(C)

&A[0][0][0] + w(x * y * p + z * q+ r)

(D)

&A[0][0][0] + w(x * y * q + z * p + r)

Answer

Please comment below if you find anything wrong in the above post
Feeling lost in the world of random DSA topics, wasting time without progress? It's time for a change! Join our DSA course, where we'll guide you on an exciting journey to master DSA efficiently and on schedule.
Ready to dive in? Explore our Free Demo Content and join our DSA course, trusted by over 100,000 geeks!

Last Updated :
Share your thoughts in the comments