1/16
Vocabulary flashcards covering looping constructs, evaluation rules, and course programming standards from Chapter 6.
Iteration
One execution of all statements found inside the body of a loop.
Loop control expression
The condition that determines whether the task to repeat is finished.
Pretest loop
A loop in which the control expression is evaluated before each iteration, including the first iteration, and where the initialization of the loop control variable must take place outside the body.
Post-test loop
A loop in which the minimum number of times that the statements found inside of the loop are executed is one.
Loop update
The action that is responsible for changing the result of the loop control expression from true to false.
Loop control variable
A variable that is commonly a part of the loop control expression and the recipient of the loop update action.
Event-controlled loop
A loop where we do not know the number of times that the actions found inside the body of the loop will be executed.
Counter-controlled loop
A loop that may execute a constant number of iterations or iterate a number of times that depends on the value of a single variable or expression.
Pretest loop evaluation count
The number of times that the loop control expression is evaluated, which is one more than the number of iterations.
while loop
A looping construct that requires the use of parentheses around the loop control expression.
do-while loop
A looping construct that terminates with a semicolon after its loop control expression.
Braces { and } (Course Standard)
Syntactic construct that is required by course standards to always be used with all looping constructs, similar to their required use in the if construct.
Main function control structures (Course Standard)
Permissible only in a limited amount in the main function to ensure that it makes most of the function calls for a program.
Input validation
An example of an event-controlled problem for which selection by itself is insufficient because it provides only a finite number of opportunities for the user to input valid data.
Input validation scope (Course Standard)
The requirement to validate for the input of both the range of acceptable values and the correct data type, commonly expected to be found in the same function containing the prompt for input and scanf statement.
Short-circuit evaluation in loops
A method of evaluating logical expressions that does apply to loop control expressions.
Control-forcing statements (Course Standard)
Statements such as break, continue, exit, and the use of multiple return statements in a user-defined function, which are prohibited by course standards as mechanisms to terminate repetitive processes.