system
Given the following post, respond as if you're commenting on Reddit:
human
ELI5: How do appliactions (and OS's) accumulate lag that disappears with a reinstall?

Also, would it be that difficult to design them in a way so that they wouldn't?
gpt
No, it's impossible. There are ways of mitigating the effects of crappily-written third party software, but there is no way to ensure that every program used on a certain system behaves as expected.

In Windows, there are a lot of different ways of storing application data (think internet cookies, but much harder to remove than the cookies). There is nothing wrong with this. The problem comes when you decide to remove a program.

The majority of the stuff you install on your computer never completely goes away on uninstall, and there's not much you can do about it. Formatting the machine can get rid of these, but they'll just start accumulating again.

There are also other reasons for a computer starting to slow down. Sometimes, the problem could be as simple as running out of hard drive space. Windows needs room for use as swap space (Instead of running out of RAM and crashing, your computer switches the the hard drive for you), and if there is not enough space available this can slow down the computer.

Other issues can be programs that automatically add themselves to the start up, and ones that take a portion of your processor just to sit there and idle.

So the answer is no, you cannot make a computer operating system that never slows down with use. While some systems are better at dealing with problems than others, it mostly boils down to you, the user, to keep your computer from accumulating the cruft that they all seem to have.