Professional Documents
Culture Documents
computer science objective type questions pdf computer science multiple choice questions with
answers pdf
mcq in computer science pdf multiple choice questions in computer science pdf download computer
science multiple choice questions with answers doc computer science quiz questions with answers pdf
computer basics mcq pdf
Toggle navigation
HOME / ALL CATEGORIES / DATA STRUCTURES AND ALGORITHMS / SORTING AND SEARCHING /
1.
a.
Exhibits the worst case performance when the initial array is sorted in reverse order.
b.
c.
Can be compared to the way a card player arranges his card from a card deck.
d.
Answer: (d).
2.
Tree
b.
Heap
c.
Hash Table
d.
Linked-List
Answer: (c).
Hash Table
3.
a.
Bubble Sort
b.
Quick Sort
c.
Merge Sort
d.
Insertion Sort
Answer: (b).
Quick Sort
4.
a.
Selection Sort
b.
Bubble Sort
c.
Merge Sort
d.
Insertion Sort
Answer: (a).
Selection Sort
5.
a.
Merge Sort
b.
Quick Sort
c.
Insertion Sort
d.
Selection Sort
Answer: (b).
Quick Sort
6.
a.
linear search
b.
binary search
c.
merge sort
d.
quick sort
Answer: (a).
linear search
7.
a.
Ο(m | n)
b.
Ο(m + n)
c.
Ο(m log n)
d.
Ο(n log m)
Answer: (b).
Ο(m + n)
8.
a.
Greedy approach
b.
c.
Dynamic Programming
d.
Answer: (d).
9.
a.
size of array
b.
pivot element
c.
sequence of values
d.
Answer: (b).
pivot element
10.
a.
Insertion Sort
b.
Merge Sort
c.
Shell Sort
d.
Heap Sort
Answer: (b).
Merge Sort
11.
Which of the following searching techniques do not require the data to be in sorted form
a.
Binary Search
b.
Interpolation Search
c.
Linear Search
d.
Answer: (c).
Linear Search
12.
Which of the below given sorting techniques has highest best-case runtime complexity
a.
quick sort
b.
selection sort
c.
insertion sort
d.
bubble sort
Answer: (b).
selection sort
13.
How many swaps are required to sort the given array using bubble sort - { 2, 5, 1, 3, 4} ?
a.
b.
5
c.
d.
Answer: (a).
14.
a.
b.
c.
d.
Answer: (b).
15.
The following sorting algorithms maintain two sub-lists, one sorted and one to be sorted −
a.
Selection Sort
b.
Insertion Sort
c.
Merge Sort
d.
both A & B
Answer: (d).
both A & B
16.
a.
interpolation search
b.
linear search
c.
merge sort
d.
Answer: (b).
linear search
17.
(N/2)+1
b.
(N+1)/2
c.
(N-1)/2
d.
(N+2)/2
Answer: (b).
(N+1)/2
18.
In ……………, search start at the beginning of the list and check every element in the list.
a.
Linear search
b.
Binary search
c.
Hash Search
d.
Answer: (a).
Linear search
19.
a.
True, False
b.
False, True
c.
False, False
d.
True, True
Answer: (d).
True, True
20.
a.
Insertion Sort
b.
Bubble Sort
c.
Merge Sort
d.
Heap Sort
Answer: (c).
Merge Sort