1. The public pay for and build the lines and prove market demand.
2. Decades later some 'fiscal conservatives' get elected.
3. Who then privatize them for a sweetheart deal to their friends.
4. Who then proceed to squeeze every penny they have out of the public, while foregoing expansion and service quality.
With an end result of everyone getting to pay through the nose for shit service, while profits accrue up. And nobody's building any competing lines, because rail is a textbook example of a natural monopoly, and it's hard to compete on capex with someone who got a full rail network by buying it, fully built out[1].
Nobody with a lick of sense will ever lend you the 100 billion dollars you need to open a from-scratch competitor, if you ever want to eat into the incumbent's margins. The incumbent knows this.
---
The rail company is the poster child for either a crown corporation, or at most, a 'customer-facing services outsourced on a fixed-term-contract'.
---
[1] Bonus points for rules around eminent domain changing at some point in the past century and a half, making it actually impossible to build a competing line today.
Some not-very-light reading about the rise and fall of JNR:
https://www.substack-bahn.net/p/aura-of-success-the-first-ye...
https://www.substack-bahn.net/p/the-death-and-privatization-...
https://www.substack-bahn.net/p/the-death-and-privatization-...
As of 1996, JR group still controls over 20,000 km of Japan's 30,000 km of rail, and that's after privatizing and closing a large slab of it (mostly those duplicated by Shinkansen).
Further, JR started private. It was nationalized in 1906. The Tokaido Line and tha Sanyo Line already built by private companies. They forced out 17 other companies and then ran it into the ground.
The only place private "might" not have built is rural and JR built those mostly as "pork-barrel" (favors to politians) when it was run by the government. I also say "might" because it is/was common, not just in Japan, to build housing and trains to that housing. You pick a place like Enoshima, build a few 1000s homes, build a train out there to sell the homes. So "rural" places do get private trains.
Japan's system is almost entirely private and is best in the world by nearly every metric. We (the people) do not owe support to depopulated areas. If you choose to live in the boonies the government is not required to build or maintain roads, tracks, sewers, power to your place. Funds are not infinite.
Japan's private system works because the government mostly got out of the way and let them build and run complementary businesses. Most other countries either make them public, and then they eventually are underfunded and are prevented from expanding/responding, OR, if they do let them be private they find some other way to cripple them like by disallowing other interests.
https://worksinprogress.co/issue/why-japan-has-such-good-rai...