How many sovereign states have successfully detonated nuclear weapons?

History Trivia: How many sovereign states have successfully detonated nuclear weapons?