The short answer
If your goal is Bitcoin, Litecoin or Kaspa hashrate, buy an ASIC. Purpose-built machines dominate those algorithms on efficiency and hashrate per watt, and a GPU cannot compete on SHA-256 or KHeavyHash at scale.
If you need one machine for several algorithms, graphics rendering or AI workloads, a GPU rig is more flexible. A multi-GPU system can switch coins and also earn outside mining, but it gives up the single-purpose efficiency of an ASIC.