Why Switzerland built a 2-kilometer-long train
https://edition.cnn.com/travel/article/world-record-train-switzerland/index.html
Mountainous topography is suitable for railway usage. That's because population density naturally becomes higher, when many people have to live in plane areas in mountainous region.
Hong Kong, Nagasaki ,and Busan would be typical examples.