官术网_书友最值得收藏!

Concurrent versus sequential

Perhaps the most obvious way to understand concurrent programming is to compare it to sequential programming. While a sequential program is in one place at a time, in a concurrent program, different components are in independent, or semi-independent, states. This means that components in different states can be executed independently, and therefore at the same time (as the execution of one component does not depend on the result of another). The following diagram illustrates the basic differences between these two types:

Difference between concurrent and sequential programs

One immediate advantage of concurrency is an improvement in execution time. Again, since some tasks are independent and can therefore be completed at the same time, less time is required for the computer to execute the whole program.

主站蜘蛛池模板: 奉节县| 双江| 苏尼特右旗| 松溪县| 武功县| 南京市| 柳州市| 长丰县| 海安县| 沙洋县| 越西县| 桃园县| 阿拉善盟| 濮阳市| 澄迈县| 白水县| 察雅县| 筠连县| 南木林县| 吉隆县| 韶关市| 麟游县| 荔波县| 卢湾区| 和平县| 安阳市| 邢台市| 日土县| 淅川县| 佛教| 高阳县| 天峻县| 类乌齐县| 沂源县| 泗阳县| 周至县| 玉山县| 格尔木市| 汉中市| 林甸县| 呈贡县|