?? loop.java
字號:
public class Loop extends Statement { private Expression condition; private Statement body; String operazione; int valore; public Loop(Expression c, Statement s) { body = (Statement)s.clone(); condition = (Expression)c.clone(); } public void run() throws ExecutionException { while (condition.eval() == 1) body.run(); } public Object clone() { return new Loop(condition, body); } /* --------------------------------------- * lj: condition * jzero li * body * jump lj * li: ... */ public String toString() { int truelabel = ++labels, falselabel = ++labels; toLabel = truelabel; String result = condition.toString()+labelling()+"JZERO L"+falselabel+"\n"+body.toString()+labelling()+"JUMP L"+truelabel+"\n"; toLabel = falselabel; return result; }}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -