Well having computers to help design stuff helps. The F-117 was limited by the number of faces the computer at the time could simulate. If CAD had been around during the design of the Shuttle they could have put diagnostics into the engines and wouldn't have had to rebuild them every three flights. The shuttle computer was so bad by today's standards that they couldn't fit all of the software on a single drive. The had separate modules from takeoff, orbit, and landing so that when they got into orbit and when they were ready to descend the astronauts had to hit a button that would shut the computer off, change the drive it was reading, and reboot.
Oh and we still have no idea how to simulate rocket plumes effectively.
Did we have money waste on the moon the first time? It cost about half a trillion dollars (in today's money) and I want to say the estimated return was 13:1, but that's from memory and could be very wrong. Regardless the space race spurred the semiconductor industry and had many other spinoffs, today the Merlin engine that SpaceX makes is based on the J-2 used in the Saturn rockets.
We don't know what we'll get, we don't know what we'll learn
He has not acquired a fortune; the fortune has acquired him. -- Bion