Private companies built railroads in the 1800s.
Imagine.
Private companies were given the right of way and land to be able to afford to build the railway.
And almost all of them went broke at least once. I think the Georgia Railroad was one of the few that avoided bankruptcy because the banking subsidiary was highly profitable and they got favorable tax treatment from the state.