First, you're confusing "the public" with the government.
Second, if you mean "Why would you assume that the government would have chosen nuclear war", then you're assuming the government would have understood the choices and their consequences, which if you study your cold war history you will find is incorrect.
In fact, I'd suggest brushing up on your history if you aren't aware of the substantial part of each government that was prepared to choose nuclear war. This is not "assumption"; it's documented history.
Here's a simpler question: if the secrecy weren't needed to make the missiles go away, then why didn't they go away (on the authority of those from whom the deals were kept secret) without the secret dealings?