Vienna's population intensely declined after it was no longer the seat of a large empire, which gave the government an opportunity to buy up land for cheap. Vienna's population is still lower than it was in 1916, which explains why housing is relatively affordable there. It's not something easily replicable in other cities.