

MCQOPTIONS
Saved Bookmarks
This section includes 30 Mcqs, each offering curated multiple-choice questions to sharpen your Computer Science Engineering (CSE) knowledge and support exam preparation. Choose a topic below to get started.
1. |
A graph in which all vertices have equal degree is known as ____ |
A. | Complete graph |
B. | Regular graph |
C. | Multi graph |
D. | Simple graph |
Answer» B. Regular graph | |
2. |
A graph is a tree if and only if graph is |
A. | Directed graph |
B. | Contains no cycles |
C. | Planar |
D. | Completely connected |
Answer» C. Planar | |
3. |
Minimum number of fields in each node of a doubly linked list is____ |
A. | 2 |
B. | 3 |
C. | 4 |
D. | None of the above |
Answer» C. 4 | |
4. |
A vertex of in-degree zero in a directed graph is called a/an |
A. | Root vertex |
B. | Isolated vertex |
C. | Sink |
D. | Articulation point |
Answer» D. Articulation point | |
5. |
The elements of a linked list are stored |
A. | In a structure |
B. | In an array |
C. | Anywhere the computer has space for them |
D. | In contiguous memory locations |
Answer» D. In contiguous memory locations | |
6. |
Which of the following data structure can t store the non-homogeneous data elements? |
A. | Arrays |
B. | Records |
C. | Pointers |
D. | Stacks |
Answer» B. Records | |
7. |
To perform level-order traversal on a binary tree, which of the following data structure will be required? |
A. | Hash table |
B. | Queue |
C. | Binary search tree |
D. | Stack |
Answer» C. Binary search tree | |
8. |
A parentheses checker program would be best implemented using |
A. | List |
B. | Queue |
C. | Stack |
D. | Any of the above |
Answer» D. Any of the above | |
9. |
Which of the following data structure is required to convert arithmetic expression in infix to its equivalent postfix notation? |
A. | Queue |
B. | Linked list |
C. | Binary search tree |
D. | None of above |
Answer» E. | |
10. |
Quick sort is also known as .. |
A. | merge sort |
B. | tree sort |
C. | shell sort |
D. | partition and exchange sort |
Answer» E. | |
11. |
If two trees have same structure and node content, then they are called ____ |
A. | Synonyms trees |
B. | Joint trees |
C. | Equivalent trees |
D. | Similar trees |
Answer» D. Similar trees | |
12. |
The time complexity of quicksort is .. |
A. | O(n) |
B. | O(logn) |
C. | O(n2) |
D. | O(n logn) |
Answer» E. | |
13. |
Finding the location of a given item in a collection of items is called |
A. | Discovering |
B. | Finding |
C. | Searching |
D. | Mining |
Answer» D. Mining | |
14. |
The total number of comparisons in a bubble sort is . |
A. | O(n logn) |
B. | O(2n) |
C. | O(n2) |
D. | O(n) |
Answer» B. O(2n) | |
15. |
. sorting is good to use when alphabetizing a large list of names. |
A. | Merge |
B. | Heap |
C. | Radix |
D. | Bubble |
Answer» D. Bubble | |
16. |
form of access is used to add and remove nodes from a queue. |
A. | LIFO, Last In First Out |
B. | FIFO, First In First Out |
C. | Both a and b |
D. | None of these |
Answer» C. Both a and b | |
17. |
New nodes are added to the of the queue. |
A. | Front |
B. | Back |
C. | Middle |
D. | Both A and B |
Answer» C. Middle | |
18. |
The situation when in a linked list START=NULL is . |
A. | Underflow |
B. | Overflow |
C. | Houseful |
D. | Saturated |
Answer» B. Overflow | |
19. |
Which of the following are two-way lists? |
A. | Grounded header list |
B. | Circular header list |
C. | Linked list with header and trailer nodes |
D. | List traversed in two directions |
Answer» E. | |
20. |
To represent hierarchical relationship between elements, which data structure is suitable? |
A. | Dequeue |
B. | Priority |
C. | Tree |
D. | Graph |
Answer» D. Graph | |
21. |
Identify the data structure which allows deletions at both ends of the list but insertion at only one end. |
A. | Input restricted dequeue |
B. | Output restricted qequeue |
C. | Priority queues |
D. | Stack |
Answer» B. Output restricted qequeue | |
22. |
What is the postfix form of the following prefix: *+ab cd |
A. | ab+cd * |
B. | abc+* |
C. | ab+*cd |
D. | ab+*cd |
Answer» B. abc+* | |
23. |
What is the functionality of the following code? Choose the most appropriate answer. public int function(){if(head == null)return Integer.MIN_VALUE;int var;Node temp = head;Node cur;while(temp.getNext() != head){cur = temp;temp = temp.getNext();}if(temp == head){var = head.getItem();head = null;return var;}var = temp.getItem();cur.setNext(head);return var;} |
A. | return data from the end of the list |
B. | returns the data and deletes the node at the end of the list |
C. | returns the data from the beginning of the list |
D. | returns the data and deletes the node from the beginning of the list |
Answer» C. returns the data from the beginning of the list | |
24. |
Suppose you are given an implementation of a queue of integers. The operations that can be performed on the queue are:i. isEmpty (Q) returns true if the queue is empty, false otherwise.ii. delete (Q) deletes the element at the front of the queue and returns its value.iii. insert (Q, i) inserts the integer i at the rear of the queue.Consider the following function:void f (queue Q) {int i ;if (!isEmpty(Q)) {i = delete(Q);f(Q);insert(Q, i);}}What operation is performed by the above function f ? |
A. | leaves the queue q unchanged |
B. | reverses the order of the elements in the queue q |
C. | deletes the element at the front of the queue q and inserts it at the rear keeping the other elements in the same order |
D. | empties the queue q |
Answer» C. deletes the element at the front of the queue q and inserts it at the rear keeping the other elements in the same order | |
25. |
public int function() { if(head == null) return Integer.MIN_VALUE; int var; Node temp = head; while(temp.getNext() != head) temp = temp.getNext(); if(temp == head) { var = head.getItem(); head = null; return var; } temp.setNext(head.getNext()); var = head.getItem(); head = head.getNext(); return var; } What is the functionality of the following code? Choose the most appropriate answer. |
A. | return data from the end of the list |
B. | returns the data and deletes the node at the end of the list |
C. | returns the data from the beginning of the list |
D. | returns the data and deletes the node from the beginning of the list |
Answer» E. | |
26. |
Consider the following statements:i. First-in-first out types of computations are efficiently supported by STACKS.ii. Implementing LISTS on linked lists is more efficient than implementing LISTS onan array for almost all the basic LIST operations.iii. Implementing QUEUES on a circular array is more efficient than implementing QUEUESon a linear array with two indices.iv. Last-in-first-out type of computations are efficiently supported by QUEUES.Which of the following is correct? |
A. | (ii) and (iii) are true |
B. | (i) and (ii) are true |
C. | (iii) and (iv) are true |
D. | (ii) and (iv) are true |
Answer» B. (i) and (ii) are true | |
27. |
A binary tree in which all its levels except the last, have maximum numbers of nodes, and all the nodes in the last level have only one child it will be its left child. Name the tree. |
A. | Threaded tree |
B. | Complete binary tree |
C. | M-way search tree |
D. | Full binary tree |
Answer» C. M-way search tree | |
28. |
Which of following data structure is more appropriate for implementing quick sort iteratively? |
A. | Deque |
B. | Queue |
C. | Stack |
D. | Priority queue |
Answer» D. Priority queue | |
29. |
If two trees have same structure and but different node content, then they are called ___ |
A. | Synonyms trees |
B. | Joint trees |
C. | Equivalent trees |
D. | Similar trees |
Answer» E. | |
30. |
The number of edges in a complete graph of n vertices is |
A. | n(n+1)/2 |
B. | n(n-1)/2 |
C. | n2/2 |
D. | n |
Answer» C. n2/2 | |