On land gifted to them by the government.
Indeed, that, if anything, is exactly the kind of investments that a government should be making.
The government well made its money back before the great railway crash.
Let's say the Internet suffers a crash in a few decades. Few would argue that any previous investment into the Internet was not worth it.