Defragging is helpful, but if you keep a tidy HD and reasonable housekeeping it shouldn't be necessary very often with normal use.
Scandisk is the one that may take ages if you have more than desktop running when you use it.
Scandisk in my view should be run as little as possible, unless demanded of you by Windows. It does put (a tiny) extra stress on a HD which may well be in top order anyway.
For me, after being too ambitious at times, frozen and having to reboot,- then Windows scolds me and tries to scandisk everything in sight. If I am in a hurry I press X to exit and all seems well. Just occasionally I sit back and let it get on with it.