跳转到内容

Harbour 应用程序开发/控制结构

来自维基教科书,开放世界中的开放书籍
[DO] WHILE condition
    ...
    [LOOP]
    [EXIT]
END[DO]
FOR var := init_exp TO end_expr [STEP step_expr]
    ...
    [LOOP]
    [EXIT]
NEXT
FOR EACH var IN collection_expr
    ...
    [HB_EnumIndex()]
    [LOOP]
    [EXIT]
NEXT
IF condition
    ...
[ELSEIF condition]
    ...
[ELSE]
    ...
END[IF]
SWITCH condition
    CASE literal_expr
        ...
        [EXIT]
    [CASE literal_expr]
        ...
        [EXIT]
    [DEFAULT]
        ...
END

BEGIN SEQUENCE

[编辑 | 编辑源代码]
BEGIN SEQUENCE
    ...
    [BREAK]
    [Break([expression])]
[RECOVER [USING var]]
    ...
END [SEQUENCE]
华夏公益教科书