Preserving the code for future generations to come is absolutely a good idea, but are they really helpful for those generations? I would say a partial yes and no answer for it. There are both merits and demerits associated with the preservation of code for such longer centuries and generations to come. Speaking from a historic point of view, the Earth after few centuries would be completely different than what we are today and people would be using a newer technology or might have moved completely to a newer invention to come and what not?
People of the distant future might be ridiculously sophisticated than what we currently are in this generation. Codes might not be the same as what we have them today, and just for comparison, C and Python. C is a mix of different jargons and weird syntaxing whereas Python is useful across all platforms with simplicity and easy to use codes. Then again, C is still usable in today's standard competing against the larger, broader proglang in the market. Why? It is because these ancient coding languages are the basis of some of the modern proglangs that we have today. History is quite an impressive teacher, I must say.
For instance, a 100 years back may be at 1920s people would have never thought they can speak with people on the other side of the globe or they can connect with the other side of the globe in just a few seconds. People would have never had an idea that there would be no usage of physical money in future and everything would be digitized. Hence, someone from 2120 would be way more different than what we are today and the current technologies could be childish for them!
And most technology that we have today are concepts that were already established a hundred years back--even a thousand years!--albeit being primitive in form. The usage of the wheel has been around since the Roman times; the idea of a helicopter was proposed as early as the Renaissance in times of Da Vinci; the first undersea cable, the Transatlantic telegraph cable was laid down in the 1850s to make communication from East to West perfectly possible albeit the physical separation of two distinct points of land.. I could go on and mention technology that were available back then and still operational and used widespread today. As for the concept of physical cash, it is still here today, isn't it? Digitizing money wasn't even a thing until the '90s and early 2000s through electronic bank transfers, but then again we still use physical cash alongside digital currencies, so overall, moot point.
So, development seems to be rapid and drastic within 100 years but what would be the position of globe during 3020? No one ever really knows if the current homo sapiens would survive to that extent or might get destroyed within few centuries. Elon Musk is planning up for a Mars settlement in a few decades so probably in 3020 people would be travelling between planets? Quite interesting to hear isn't? Can a future developer understand this far more backward under-developed code written in a language which he can't even understand?
As I've said above, most technologies of today--or possibly even the future--are just improved iterations of what already exist. For primitive code, that's why you have tech historians that study just the thing in order to understand these things as accurate as possible.
Have you even wondered how Man transcribed what was written in the Rosetta stone and Dead Sea Scrolls albeit being written in an entirely unrecognized language? Yep, historians and scholars.
The blueprints for Saturn V are lost and probably a space shuttle of such a huge mass can never be reconstructed again unless we have the exact construction plans of them.
True, but where do you think space engineers and Elon Musk get their idea of building rockets with higher thrust-to-weight ratio? From previous iterations of rockets that were constructed before. You don't necessarily need to know what the blueprints are bit by bit in order to create the
same thing; you just have to understand
why and
how it worked. Then comes the math, science and engineering aspects of everything, piece by piece as if you are building a jigsaw puzzle from memory.
Similarly, a code might be great today but do they sound astounding after decades and centuries? Histories and futuristic thoughts are mind-boggling, but can we survive another 1000 years without hitting an asteroid? In the event of space-time these decades and centuries long development could be considered as few microseconds and nothing more.
The Eiffel Tower remains to be one of the most astounding and most beautiful piece of construction ever built, and that is even with centuries of futuristic building concepts laid in front of it (thanks, Gustave Eiffel). Same with code. It might be as crude or as primitive as it looks, but when people figure out how it helped shaped the world that they live in currently, it becomes great and amazing to their eyes. Bitcoin? First mover advantage, literally opened people's eyes about the possibilities of currency way beyond fiat. Lots of great ideas spawned after it. Do you think people would just easily forget? I don't think so.
As for the asteroid hitting Earth, astronomers have the capability to predict whether an asteroid would be dangerously close for an impact or not, and for the next couple of centuries, there aren't any asteroids or any near-Earth objects that would be hitting our lovely planet. Heck, if anything, we would be the ones destroying this lovely place, who knows.