V2EX  ›  英汉词典

Control Flow

定义 Definition

control flow(控制流/控制流程):指程序在运行时语句与指令执行的先后顺序与路径,通常由条件判断(if/else)、循环(for/while)、跳转(return/break/continue)、异常处理(try/catch)以及函数调用等结构决定。

发音 Pronunciation (IPA)

/kənˈtroʊl floʊ/

例句 Examples

Control flow determines which lines of code run next.
控制流决定接下来会执行哪些代码行。

In this program, the control flow branches on user input, loops until a valid value is entered, and then returns from the function.
在这个程序中,控制流会根据用户输入发生分支,循环直到输入有效值,然后从函数返回。

词源 Etymology

control 来自拉丁语 contra(相对、对抗)与中古法语/拉丁语系词根演变,逐渐形成“支配、调控”的含义;flow 来自古英语 flōwan,意为“流动”。合起来 control flow 字面是“被控制的流动”,在计算机科学语境中引申为“程序执行路径的流动与调度”。

相关词 Related Words

文学/著作中的出现 Notable Works

  • Compilers: Principles, Techniques, and Tools(《编译原理》,“龙书”)——讨论控制流图(control-flow graph)与控制流分析。
  • Structure and Interpretation of Computer Programs(《计算机程序的构造和解释》)——在讲解过程、条件与递归时频繁涉及控制流思想。
  • The C Programming Language(《C 程序设计语言》)——在介绍 if/else、while、for、switch 等章节中出现并体现控制流概念。
  • Clean Code(《代码整洁之道》)——在讨论可读性与复杂度时常提到减少复杂控制流(如过深嵌套、过多分支)。
关于   ·   帮助文档   ·   自助推广系统   ·   博客   ·   API   ·   FAQ   ·   Solana   ·   2364 人在线   最高记录 6679   ·     Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 14ms · UTC 07:57 · PVG 15:57 · LAX 23:57 · JFK 02:57
♥ Do have faith in what you're doing.