
Chapter 12 Device Logic (Pawn)
12.5.6.6 Break
Terminates and leaves the smallest, encircling "do", "for" or "while" statement at any point in the loop. The
"break" statement moves the program flow to the next statement outside the loop.
Example:
example(n)
{
new a = 0
for(new i = 0; i < n ; i++ )
{
a += i
if(i>10)
break
a += 1
}
return a
}
12.5.6.7 Continue
Terminates the current iteration of the smallest encircling "do", "for" or "while" statement and moves the
program control to the conditional part of the loop.
Example
example(n)
{
new a = 0
for(new i = 0; i < n ; i++ )
{
a += i
if(i>10)
continue
a += 1
}
return a
}
Rev. 01
175
Содержание myDatalogEASY IoTmini
Страница 2: ......
Страница 11: ...Chapter 2 Declaration of conformity Chapter 2 Declaration of conformity Rev 01 11 ...
Страница 12: ......
Страница 34: ......
Страница 66: ......
Страница 78: ......
Страница 82: ......
Страница 186: ......
Страница 194: ......
Страница 196: ......
Страница 202: ......
Страница 205: ...Chapter 19 Document history Chapter 19 Document history Rev Date Changes 01 28 08 2020 First version Rev 01 205 ...
Страница 206: ......
Страница 208: ......