Two ways to find a duplicate in an array
Filed under OnceHub
The question
Write two approaches with different time or space complexities to find a duplicate in an array.
No write-up yet. Related questions below have one.
Related OnceHub questions
Collected from public candidate posts and coding forums. Updated Nov 2026.