A lot more info is needed.
I have a high end Late 2012 27" iMac, and it still feels very fast to me. I was thinking of getting the new 2019 iMacs, but I couldn't really justify it because of how well my iMac runs for what I do with it.
But, your situation could be very different.
If you could give info about the iMac you are interested in, the asking price, or what you plan in doing with it, people could answer your question.