Nuclear war is much more unpredictable than asteroids, but, unlike the dinosaurs of 66 million years ago, humans can avoid causing their own extinction.