python- differences and relations between the process of multitasking, threads, coroutines

Use of more than one task and thread

Multitasking: analogy, turn on the computer, while watching word document, while listening to music

Single-core cpu: can only do one thing at the same time

Single core cpu is able to multi-task (in fact, false multi-task) because multiple task switching quickly so that we feel are running simultaneously

Parallel: true multitasking (such as single-core 4 cpu running one task)

Concurrency: fake multi (more tasks than the number of cpu core number)

Guess you like

Origin www.cnblogs.com/wang-mengmeng/p/12535841.html