The moon is a tough place to explore. It is several days away from Earth. Solar radiation sears the moon's surface. Its gravity is lumpy, and there is no atmosphere to protect astronauts from the elements.

Yet, for a few historic years in the 1960s and 1970s, NASA made the moon its goal for human exploration. On July 20, 1969, NASA's Apollo 11 mission landed the first men on the moon. By the time Apollo 17 concluded in 1972, 12 men had walked on the lunar surface and several others had participated in orbital and flyaround missions.

"You get on top of a Saturn V rocket with enough chemical energy to be the equivalent of a small atomic bomb. Then you throw away levels of safety by going into Earth orbit, then going to the moon, orbiting around the moon. And then, on the landing missions, two of the guys going down to the surface and being at an absolute dead stop on the moon."

The "links in a chain" (as Apollo 17 commander Gene Cernan called it) or "fragile daisy chain of events" (a phrase from Apollo 11's Mike Collins) didn't end there, Chaikin added. Walking on the moon required utter confidence in the engineers at ILC Dover who created the spacesuit, and even the women who sewed it. The last three Apollo missions took an additional risk by driving away from the lunar module in a rover. [Photos: NASA's Historic Apollo 11 Moon Landing]

So mission managers worked to remove as much risk as possible from the system. For example, the service propulsion system — the main engine on the mother ship that brought astronauts into and out of lunar orbit — had no ignition system. The fuel was self-combusting, and it was pressure-fed, removing the need for fuel pumps, Chaikin said.

Every component had "the living daylights" tested out of it, which helped NASA prevail over the Russians, who were also aiming for the moon at the time. According to Chaikin, Russia's massive N1 moon rocket was never put on a test stand to see how its engines reacted together when firing. This led to a devastating explosion during a test launch.

The process did have blind spots, Chaikin acknowledged. The Apollo 1 fatal fire on the pad happened because nobody thought through what might happen in a spacecraft with a pure oxygen atmosphere, pressurized at 16.7 pounds per square inch. (A spark in the spacecraft, from a source that was never uncovered, quickly ignited flames in the oxygen atmosphere.)

But on the whole, Chaikin says, NASA engaged in enough "what-if thinking" to make even the onboard explosion of an oxygen tank on Apollo 13 survivable. For example, the docking mechanism that linked the crippled command module and healthy lunar module was strong enough to allow the lunar module to propel the combined spacecraft onto the proper course for home, Chaikin said. The astronauts lived in their lunar module "lifeboat" for several days before successfully transferring back to the command module and splashing down on Earth.

Lunar lessons learned

Participants in the Apollo program also made sure to carry on lessons from one mission to the next, Jared Woodfill told Space.com. Woodfill was the project engineer for the switches and gauges on both vehicles, as well as the "alarm guy" for the command module.

After the Apollo 1 pad fire killed three astronauts in 1967, Woodfill went over the alarm system and recommended several changes. Among them was lowering the threshold for when a "DC Power Bus" alarm came on, referring to a voltage drop in the command module's electrical system. This ended up being one of the main indicators of problems early after the Apollo 13 explosion.

"It was a very expensive change," said Woodfill, who still works at NASA. "It was not like the digital age. You had to dig into the actual hardware. You had to dig out the little resistor that would set that threshold. And you had to change all the [technical] drawings and everything."

Another example was making the switch panels moisture-resistant after Apollo 1, Woodfill said. This helped save the Apollo 13 spacecraft, because they had to turn off the command module's electrical system to save power. Although humidity caused moisture to build up on the command module switch panel, nothing shorted out when the spacecraft was turned on again.

Apollo Quiz: Test Your Moon Landing Memory

It has been more than four decades since the first men landed on the moon on July 20, 1969. Test your memory of the moon landing with this quiz.

Woodfill also identified several things that saved Apollo 11 from possible problems, ranging from how well Commander Neil Armstrong was trained for the landing, to designing the mission to fly a "free return trajectory" around the moon if the engine failed, meaning it could arrive back at Earth without the need of course corrections.

He added that it's important to keep these stories of success alive for others to learn the lessons as they design new types of spacecraft. "These stories I'm telling are good to recount. It encourages the younger generation," he said.