Address Calculation Assignment
Address Calculation Assignment
Session: (2023-24)
Class – XII
Subject : COMPUTERS SCIENCE
ASSIGNMENT
2. A character array B[7][6] has a base address 1046. Calculate the address at
B[2][3], if the array is stored
a. Row major wise
b. Column major wise
1
5. An array Ar[-4…6][-2….12] stores elements in row major wise, with the
address Ar[2][3] as 4142. If each element requires 2 bytes of storage, find
the base address.
6. Mat is a matrix created with 6 rows and 7 columns. Each element of matrix
occupies 2 bytes in the memory. If the base address of Mat[1][1] is 1500,
then find the address of Mat[4][2] when the matrix is stored as:
a. Row major wise
b. Column major wise
10.Let A[1…N] is one dimensional array whose base address is 2000 and the
array is stored sequentially in the memory. The address of last element of
array is 3000. Each element of the array requires 4 bytes of storage, find
the upper bond (higher limit) of the array A[ ].