CBSE Computer Science - Revision Tour(Solved) CBSE Guess > eBooks > Class XII > CBSE Computer Science Arrays Solved Revision Tour By Mr. Ravi Kiran COMPUTER SCIENCE ARRAYS 3.b) An array Arr[35][15] is stored in the memory along the row with each of its element occupying 4 bytes . Find out the Base address and the address of element Arr[20][5] , if the location Arr[2][2] is stored at the address 3000. Solution: Children, Try this answer as an assignment. 3.d) Write a function in C++ to print sum of all values which either are divisible by 3 or divisible by 5 present in a 2D array passed as the argument of the function. Ans:-
DELHI 2004: 3.a) Define the function SwapArray(int[ ],int),that would expect a 1D integer array NUMBERS and its size N. the function should rearrange the array in such a way that the values of that locations of the array are exchanged. (Assume the size of the array to be even). Example : Solution:
3.b) An array ARR[5][5] is stored in the memory with each element occupying 3 bytes of space. Assuming the base address of ARR to be 1500, compute the address of ARR[2][4],when the array is stored : Solution: Children, Try this answer as an assignment.
CBSE Computer Science Solved Revision Tour By Mr. Ravi Kiran ( [email protected] ) |
|