请输入您要查询的字词:

 

单词 do-while loop
释义
do-while loop

Computer
  • A form of programming loop in which the condition for termination (continuation) is computed each time around the loop. There are several variants on this basic idea. For example, Pascal has

    • while 〈condition〉 do
    • begin
    • 〈statements〉
    • end
    • and also
    • repeat
    • 〈statements〉
    • until 〈condition〉

    The first is a while loop and the second is a repeat-until loop. Apart from the obvious difference that the first specifies a continuation condition while the second specifies a termination condition, there is a more significant difference. The while loop is a zero-trip loop, i.e. the body will not be executed at all if the condition is false the first time around. In contrast, the body of a repeat-until loop must be obeyed at least once.

    Similar constructs are found in most languages, though there are many syntactic variations. See also do loop.


随便看

 

科学参考收录了60776条科技类词条,基本涵盖了常见科技类参考文献及英语词汇的翻译,是科学学习和研究的有利工具。

 

Copyright © 2000-2023 Sciref.net All Rights Reserved
京ICP备2021023879号 更新时间:2024/7/1 0:40:51