There are many numbers in an array and each number appears three times excepting for one special number appearing once. Here is the question: how can I find the special numb
Since nobody's saying it, I will: hashtable.
You can calculate how many times each element occurs in the array in O(n) with simple hashtable (or hashmap).
O(n)