Java 程式設計/關鍵字/while
外觀
while 是一個 Java 關鍵字。
它開始一個迴圈塊。
使用 擴充套件巴科斯正規化,while 的常規語法為
while-looping-statement ::=whilecondition-clause single-statement | block-statement condition-clause ::=(Boolean Expression)single-statement ::= Statement block-statement ::={Statement [ Statements ]}
例如
while ( i < maxLoopIter )
{
System.out.println("Iter=" +i++);
}
|
另請參見