The operating system's task scheduler allocates execution time to multiple tasks. By quickly switchingbetween executing tasks, it creates the impression that tasks execute sequentially.