Professional Documents
Culture Documents
1 point
a. Stack
b. Queue
c. Non-linear data structure
d. Array
3. If deletion occurs from "top", what will you write in pop() function? 1 point
a. top++
b. top- -
c. pop(top)
d. top=-1
4. In case of array implementation, stack can run into a situation where it will not be able to
insert new elements. 1 point
a. True
b. False
5. You have a queue, initially empty. You perform a sequence of operations: enqueue(5),
enqueue(3), dequeue(), dequeue(), enqueue(4). What will be the order of elements in the queue
after these operations? 1 point
a. 4
b. 5, 3, 4
c. 5
d. 5, 4
a. Array
b. Linked List
c. Queue
d. Stack
9. Which data structure does not provide insertion and deletion operations? 1 point
a. Array
b. Linked List
c. Stack
d. Dequeue
10. Which data structure follows the Last-In-Last-Out (LILO) principle? 1 point
a. Array
b. Linked List
c. Stack
d. Queue
11. If you have two stacks, how can you create a queue using those stacks? 1 point
a. combine the stacks using their closed ends and restrict push() on one stack, restrict
pop() on another.
b. combine the stacks using their opened ends and restrict push() on one stack, restrict
pop() on another.
c. Impossible
d. Another stack is needed
12. In case of array implementation, queue creates unused index spaces with time because of
deletion of elements. 1 point
a. True
b. False
13. If deletion occurs from "rear", what will you write in dequeue() function? 1 point
a. rear = rear +1
b. front = front -1
c. front = front +1
d. rear = rear -1
14. Which data structure ensures that the first element inserted is the first one to be removed?
1 point
a. Array
b. Linked List
c. Stack
d. Queue
a. insertion
b. deletion
c. update
d. returns topmost element
16. Which of the following data structures stores elements in a linear manner? 1 point
a. Tower of Hanoi
b. Linked List
c. tree
d. Queue
17. Which item(s) below can not be a group data item? 2 points
a. NID number
b. Name
c. Age
d. Address