Answers and Comments


User Avatar
Written by aleksin


This is interestingly worded question, and I belive answer is in execution times:

linear O(n), example of linear access can be traversing an array
binary O(log(n)), example of binary access can be binary search
hash O(1), example of hash access is hashmap(hashtable) with constant access time.


User Avatar
Written by CMaster


Yup, I think it is.

Here is a great blog post on execution times and big-O notations:

http://leepoint.net/notes-java/algorithms/big-oh/bigoh.html


Saved Stories

Sponsored Categories