You’re doing two loads of laundry with a washer and a dryer.
First approach is you put the first load in the washer and wait for it to finish washing, put it in the dryer and wait for it to finish drying. Then you repeat the process for your second load. The total time is two wash cycles and two drying cycles.
Optimized approach is to start second load’s wash cycle while the first load’s dry cycle is going. Now the total time is one wash cycle, one dry cycle, and some time in between a wash and dry cycle time (when both machines are in use). Much faster!
Optimizing a game is like that but finding opportunities like that in code. Technically this is only a specific type of optimization, but the general idea is to find ways to make things run more efficiently.
Latest Answers