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

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.

主站蜘蛛池模板: 盈江县| 亚东县| 壶关县| 郴州市| 荆门市| 泉州市| 玉环县| 贵南县| 当雄县| 东乡县| 营山县| 盐城市| 区。| 湘乡市| 鹤岗市| 桑日县| 土默特左旗| 洛浦县| 嘉荫县| 德州市| 怀集县| 晋宁县| 沧源| 连云港市| 临湘市| 濉溪县| 平潭县| 宜春市| 钦州市| 建宁县| 蒙城县| 汶上县| 廉江市| 合江县| 仪陇县| 安阳县| 彭泽县| 闵行区| 常山县| 会昌县| 菏泽市|