Castro, in his letter, explained to Khrushchev that should the US attempt to invade and occupy Cuba, the country would pose such a threat that the Soviet Union could not risk the possibility of a preemptive nuclear strike by the US.
"I tell you this because I believe that the imperialists' aggressiveness makes them extremely dangerous, and that if they manage to carry out an invasion of Cuba — a brutal act in violation of universal and moral law — then that would be the moment to eliminate this danger forever, in an act of the most legitimate self-defense. However harsh and terrible the solution, there would be no other," Castro wrote.
Meanwhile, Khrushchev wrote to Kennedy declaring he was willing to remove the missiles from the island if the United States would pledge never to invade Cuba.
Here's an excerpt of his letter: "I propose: We, for our part, will declare that our ships, bound for Cuba, will not carry any kind of armaments. You would declare that the United States will not invade Cuba with its forces and will not support any sort of forces which might intend to carry out an invasion of Cuba. Then the necessity for the presence of our military specialists in Cuba would disappear."