# In which of the following case jump search performs better than interpolation search?

+1 vote
In which of the following case jump search performs better than interpolation search?

(a) When array has uniformly distributed values but is not sorted

(b) when array is sorted and has uniform distribution of values

(c) when array is sorted but the values increases exponentially

(d) when array is not sorted

I have been asked this question in homework.

My question is based upon Searching in section Searching of Data Structures & Algorithms II

+1 vote
by (687k points)
selected by

Correct option is (c) when array is sorted but the values increases exponentially

The explanation is: In case of non uniform distribution of values the time complexity of interpolation search is O(n) whereas the average time complexity of jump search is O(n^1/2). So in such a case jump search has a better performance.

+1 vote
+1 vote
+1 vote
+1 vote
+1 vote
+1 vote
+1 vote
+1 vote
+1 vote
+1 vote
+1 vote
+1 vote
+1 vote
+1 vote
+1 vote
+1 vote
+1 vote
+1 vote