An algorithm based on sorting can operate hundreds, or even thousands(!) of times faster.Prove it. Where's your benchmark showing that the problem described by the OP is hundreds or thousands of times faster when sorting instead of using hashes.
In reply to Re^4: Find duplicate elements from an array
by JavaFan
in thread Find duplicate elements from an array
by tej
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |