In which scenario is a HashSet more appropriate than a TreeSet?
When you need to ensure elements are sorted
When duplicate elements must be allowed
When element insertion order must be preserved
When looking for the highest efficiency in addition and search operations without needing order