My wife and I are staying in Oslo for 4 nights at the end of May; we are interested in visiting Bergen. The train from Oslo to Bergen looks amazing, so we're thinking of taking that and flying back the next day.
Yes, Bergen is quite small, so I think you'll be able to cover the most important things in one day, as the most important sights in Bergen are located very close to each other. You should take a train ride up to the top of Fløyfjellet with Fløibanen, and the famous pier ( Bryggen ) is very close to the station og station.
Mentioned in this answer:
The trainride to Bergen could indeed be wonderful at the end of May but that is very much depending on the weather on the westcoast of Norway. If you want to take the train then make sure to reserve a seat on the train at www.nsb.no
I am not very familiar with Bergen so I can not recommend places to go, but I remember that the city centre was pretty nice.
Not really ... but that doesn't mean you can't have fun. Bergen is a super city for aimless walking around. Sooooo nice. I could live there easily with all the hiking trails!