Chapter

While Loops

From ComputerScienceOne by Dr Chris Bourke

Concepts

  1. How are while loops structured and styled in PHP?

    "PHP supports while loops, for loops, and do-while loops using the keywords while, for, and do (along with another while). Continuation conditions for loops are enclosed in parentheses, (...) and bloc

  2. Why should a while-loop condition not end with a semicolon in PHP?

    "The continuation condition does not contain a semicolon since it is not an executable statement. Just as with an if-statement, if we had placed a semicolon it would have led to unintended results. Co

While Loops | ComputerScienceOne | Bifalgorithm | Bifalgorithm