CS-3 |
||
REVISION TEST SERIES - 3 |
||
Class XII |
COMPUTER SCIENCE |
Time : 1 hr. |
SET - A |
Marks : 30 |
1. | Define data structure | 1 | ||||||||||||||||
2. | What is the content of Start or Header in a linked list? | 1 | ||||||||||||||||
3. | Write a function in C++ which accepts an integer array and its size as arguments and assign the elements into a 2D array of the following format? If we give 1, 2, 3 The resultant array will be
|
2 | ||||||||||||||||
4. | An array MA [50] [30] is sorted along the row in the memory with each element requiring 4 bytes of storage. If the element MA [10] [15] is stored of 21500, then find out the base address of the array and the memory address of element stored at location MA [30] [25]? | 2 | ||||||||||||||||
5. | What is the difference between an array and a stack housed in an array? Why is stack called a LIFO data structure? Explain how push and pop operations are implemented on a stack. | 3 | ||||||||||||||||
6. | Write a function PUSHBOOK ( ) in C++ to perform insert operation on a Dynamic Stack. which contains Book_no and Book_Title. Consider the following definition of NODE, while writing your C++ code. struct NODE { char Book No; char Book_Title [20]; NODE *Next; }; |
4 | ||||||||||||||||
7. | Write a function to sort any array of n elements using insertion sort Array should be passed as argument to the function | 3 | ||||||||||||||||
8. | Write a function New MAT(int A ( ) O. int r, int c) in C++ Which accepts a 2d array of integer and ;Es size as parameters divide all those array elements by G which are not in the range 60 to 600 (both values inclusive) in the 2d Array. | 3 | ||||||||||||||||
9. | Give postfix form for A+[(B + C} + (D + E) * F]/G | 2 | ||||||||||||||||
10. | Write the definition of a user definer function ROW (int Z[ [3]. int R int c) in C++ that will store the elements in the following manner. class student All elements except the 1st row first element is replace by the 2nd element.
|
2 | ||||||||||||||||
OR | ||||||||||||||||||
|
||||||||||||||||||
11. |
|
3 | ||||||||||||||||
12. | Each node of a STACK contains the following information, in addition to required pointer field.
TOP Is a pointer points to the topmost node of the STACK. Write the following functions.
|
4 |
0 comments:
Post a Comment