Usually the duplicate answers happen in unison. If it's an easy question, there are usually around 5 answers posted simultaneously. If this happens, you're usually supposed to delete your answer if you see a better one, but as you can imagine there are different criteria used to determine which answer is better. Ultimately this is solved by the voting and answer selection by the asker.