While I agree with the sentiment that sending manned missions to the Moon is kinda useless, unfortunately diverting those money to "noble purposes" is an utopia because that's not how things work.
In practice if those billions don't fund NASA programs they go into making some billionaires richer, Oracle laying off 30,000 people to fund data centers that will be obsolete by the time they are ready and similar stuff. Not a dime towards noble goals of humanity.