Disclamer: I'm not talking about FTL travel here. I'm also not talking about any weird space warping mechanics like wormholes and such.
I've always thought that if a star was 4 light years away, then it would be impossible to reach it with less than 4 years of travel time. Therefore, any star more than 100 light years away would require multiple generations on the ship in order to get there even if they travelled at the speed of light(or close to it). The people who set off on the mission wouldn't be alive when the spaceship arrived at the star.
But the other day I had a realisation that, for anyone travelling close to the speed of light(0.999c), the length between them and the star would contract and they could get there almost instantly(in their reference frame). This also makes sense for someone observing from earth; they would see me take about 100 years to get to this star, but, because I'm going so fast, they would see me barely age. By the time I had got to the star, they would observe me still being about the same age as I was when I set off, even though they are 100 years older. In my reference frame, I would have also barely aged and I would have reached a star that's 100 light-years away in a lot less than a 100 years of travel time.
So is this assessment correct? Could I reach a star that's 100 light years away in my lifetime by going close to the speed of light?
It would be good to get an answer in two parts: In a universe that's not expanding, and in a universe that is expanding.