A word of caution applies when recovering from the use of "CleanMyMac" and other, similarly categorized "cleaning" scam products: Even if you completely uninstall them according to their instructions and remove all remaining operative components leaving no trace of them, the effects of actually having used them to "clean" the Mac of what they consider "junk" or unnecessary files will not be reversed. Those effects are due to the deletion of necessary files in the user space — which is completely permissible under Apple's App Store review guidelines. The effects can range from poor performance, diminished battery life, increased energy consumption with the related fan noise, unpredictable behavior, crashes... all sorts of miseries. Those effects will not be reversed by reinstalling macOS for the simple reason that macOS itself is unalterable.
That is the reason I recommend completely erasing the affected Macs and reconfiguring them from the ground up. Although less drastic solutions are possible, they require hands-on, in-depth, time-consuming efforts from highly experienced Mac users. For anyone without an abundance of those resources erasing the Mac is the most practicable solution.
So how do you know whether it's necessary to do that or not? The short answer is that if your Mac is working to your satisfaction after completely removing all traces of its prior existence, then you're good. If not, less fortunate Mac users can easily be convinced their Mac has simply grown old and tired and it's time to replace it. Apple certainly won't mind.
Rule 1 of Macs is don't install junk. It's the first step in a well-worn path to misery.