Optym interview question

Find all the duplicates elements in an array?