This is documentation for Mathematica 3, which was
based on an earlier version of the Wolfram Language.
View current documentation (Version 11.2)
 Documentation / Mathematica / Other Information / Menu Commands / Edit Menu  /
Check Balance

▪ Check Balance expands the selection to cover the nearest pair of matched bracketing characters. This command selects nested (e.g ., parenthesized) expressions outward from the insertion point.
▪ To select a nested expression:

1. Select anywhere within the expression by clicking.
2. Choose Check Balance .
3. Repeat to expand the selection to the next pair of enclosing parentheses, brackets, or braces.

▪ Each time you choose Check Balance , Mathematica expands the selection in both directions until it finds pairs of matching parentheses, brackets, or braces: ([{}]). Repeating the command expands the selection one level at a time.
▪ You can use the Check Balance command to check the structure of mathematical expressions. If you have unbalanced parentheses, for example, or parentheses incorrectly balanced with brackets or braces, Mathematica beeps. (Choose Why the Beep? to identify the mistake.) If you position the insertion point (blinking vertical bar) inside a bracketed expression and choose Check Balance , Mathematica should select the whole expression. If not, you have a missing bracket somewhere.
▪ Mathematica cannot balance a selection that spans more than one cell.
▪ Keyboard shortcuts: B ; B B