Glossary
--------

loop:
   A statement that executes repeatedly while a condition is true or
   until some condition is satisfied.

infinite loop:
   A loop whose condition is always true.

body:
   The statements inside the loop.

iteration:
   One pass through (execution of) the body of the loop, including the
   evaluation of the condition.

tab:
   A special character, written as ``\t`` in C++, that causes the cursor
   to move to the next tab stop on the current line.

encapsulate:
   To divide a large complex program into components (like functions)
   and isolate the components from each other (for example, by using
   local variables).

local variable:
   A variable that is declared inside a function and that exists only
   within that function. Local variables cannot be accessed from outside
   their home function, and do not interfere with any other functions.

generalize:
   To replace something unnecessarily specific (like a constant value)
   with something appropriately general (like a variable or parameter).
   Generalization makes code more versatile, more likely to be reused,
   and sometimes even easier to write.

development plan:
   A process for developing a program. In this chapter, I demonstrated a
   style of development based on developing code to do simple, specific
   things, and then encapsulating and generalizing.


.. dragndrop:: chapter_six_glossary_one
    :feedback: Try again!
    :match_1:  loop|||A statement that executes repeatedly while a condition is true or some condition is satisfied.
    :match_2: infinite loop|||A loop whose condition is always true.
    :match_3: body|||The statements inside the loop.
    :match_4: iteration|||One pass through (execution of) the body of the loop, including the valuation of the condition.
    :match_5: tab|||A special character, written as \t in C++, that causes the cursor to move to the next tab stop on the current line.

.. dragndrop:: chapter_six_glossary_two
    :feedback: Try again!
    :match_1:  encapsulate|||To divide a large complex program into components (like functions) and isolate the components from each other (for example, by using local variables).
    :match_2: local variable|||A variable that is declared inside a function and that exists only within that function. Local variables cannot be accessed from outside their home function, and do not interfere with any other functions.
    :match_3: generalize|||To replace something unnecessarily specific (like a constant value) with something appropriately general (like a variable or parameter).
    :match_4: development plan|||A process for developing a program.
