Searching N items with no index takes how many operations on average?
AO(N squared) time
BO(1) constant time
CO(log N) time
DO(N) linear time
Answer & Solution
Correct answer: D. O(N) linear time
Without an index every item may have to be examined, so the average cost grows in direct proportion to N.
Keep practising Indexing, Address Matching, Date and City Matching
Browse all Indexing, Address Matching, Date and City Matching questions for SSC CGL, or explore more Reasoning topics.
Related questions
After 2096, which year is the next Gregorian leap year?A lunar year of 12 months is about how many days shorter than an astronomical year?How many leap years fall from 1900 to 2000, both ends included?If 1 March 2027 is a Monday, which day is 1 March 2028?In common years a leapling marks the birthday on 28 February or when?A person born on 29 February may be called what?Who reformed the Roman calendar on 1 January 45 BC?The Gregorian calendar year averages how many days?