Lists
Things important to survival
Things important to human space travel
Can these even exist on the same ranking list?
Wouldn't that logic require that nobody in the US be given a government research grant or scholarship until everyone on the planet had adequate food and housing?
Indeed. In fact, the logical conclusion is that nobody on the planet should do ANYTHING other than produce food and build houses, until everyone on the planet had adequate food and housing.
The deep flaw in this idea is, of course, that quality of life for everybody is improved (often dramatically) by the eventual results of often apparently frivolous research. All of reality 'hangs together', and no discovery, invention, theory, or observation exists in isolation from the rest of human endeavour.
In order to find water on Mars, we are forced to develop tools, techniques, ideas, theories and mechanisms that may well have far wider reaching applications than we can even dream of.
Galileo and Copernicus could reasonably have been chastised for wasting their lives on questions about the shape of the Earth, and the movement of celestial objects, when they should instead have been trying to help feed the starving masses.
But today, their work is of foundational importance in allowing massive farms to use GPS navigation, so that automated harvesters can produce food for thousands of people, with just one or two people to operate them. Nobody in Medieval Europe could have foreseen that.
Nobody today can foresee what huge benefits our space programs might have for humans hundreds of years from now. But so far, we have yet to develop a technology that has zero impact on humanity, and the VAST majority of that impact has been hugely positive, which is why ordinary middle class people have a better life today than the richest kings and emperors of the Middle Ages. And if you doubt that claim, just consider whether Henry VIII had access to a water closet and soft toilet paper - and then try living for a week without either.
There is a lot to be gained from apparently frivolous, but technically difficult, activities. Like exploring Mars, or even
building a Death Star.