break

NAME

break - exit a loop

SYNOPSIS

C shell

break

Korn shell

break [level]

DESCRIPTION

This command is a built-in command in the C shell and the Korn shell.

C shell

The break(1) command causes execution to resume after the end of the nearest enclosing foreach(1) or while(1) loop. The remaining commands on the current line are executed. Multilevel breaks are thus possible by writing them all on one line.

Korn shell

The break(1) command exits the innermost for(1), select(1), until(1), or while(1) loop specified by level. If level is not specified, the first (that is, the innermost) loop is the default.