Amazon interview question

Q. write code to detect if an array contains any duplicates?

Interview Answer

Anonymous

7 Apr 2014

Using Hash Table we can do this in O(n) time