If the ocean goes up - well they just build higher, it isn't a significant expense.
And what happens when the first floor of your building is now under water? Sure your 30th floor condo is safe but is it really practical to live there at that point?
Most of these buildings were built that way from the start, but at least one on my street was raised on jacks while pillars were put underneath. I wish I'd thought to take pictures of the process.
The exact dollar amount changes from location to location though.
More importantly: if your whole neighbourhood is 2 feet underwater, even if you're fine, the neighbourhood is toast and you're in the middle of nowhere with limited access (boats?).
Not very practical.
https://tamino.wordpress.com/2018/12/28/sea-level-rise-u-s-e...
https://tamino.wordpress.com/2017/07/24/boston-sea-level/
https://tamino.wordpress.com/2015/11/04/moon-over-miami-bost...
The last one (and related posts) is worth a look even though it isn't what you asked for because it discusses how an apparently small increase in sea level can lead to a surprising increase in flood frequency.
"trends in flood risk are driven by RSL rise", RSL = Relative Sea Level.
Edit: Sorry, I haven't had my coffee any my cynicism isn't up to normal levels yet. As mentioned, of course they'll get the state to bail them out. There's a chance they might not but as a group they're the ones with the power and the influence. Every few years some houses fall into the sea. It basically always winds up in court with the owners suing the town and/or state. I can't imagine it not going in their favor if the places underwater are in the Boston area. The cumulative political clout would be insurmountable.
That said, so what if they bail them out? If they don't bail them out then it's not like the state won't still take everyone's money and spend a large percent of it on other cause that benefits approximately nobody. As far as I care paying state cops to game the overtime system isn't any better or worse than bailing out people who's property is underwater. The difference is just hair splitting because neither of those should be happening.