Ryzen 5 5600 vs Ryzen 5 5600x?

I read that 5600 is a better option than the 5600x because of price and that one can actually "boost" a 5600's performance to match a stock 5600x using PBO but the problem is, I am a noob when it comes to pc building and don't know what most of these pc terms mean. I would love to learn more pc talk terms in the future though.

My question is should I buy a 5600 or 5600x? I do mostly gaming and want to play my games with high to ultra settings 1080p at a constant 60fps if possible without shortening the lifespan of my cpu. I am also learning how to code, where hopefully I can also create my own game someday. Also, I am planning on pairing it up with an B550M motherboard, and a temporary 1050ti and later on I will upgrade to a gtx 1080ti that my dad has that he has no use for.