Map
Index
Random
Help
Topics
th

Topic: generalized repetition

topics > computer science > programming > program control > Group: repetitive control



Topic:
simple loop
Topic:
termination of control unit

Summary

Generalized repetition consists of initialization, a loop body, one or more internal loop exits, and a loop termination. The loop-termination may be case selected by type of loop exit. The looping branch can be implicitly at the end of the loop body, or explicitly stated within the loop body.

The simplest general repetition is Dahl and others' "loop: Sl; while B; S2; repeat;". This includes both pre and post-test loops, i.e., 'while B do Sl' and 'do Sl until B'. Internal loop exits produce a contextual inconsistency. For instance with Dahl's loop the first occurrence of Sl occurs in the context of loop initialization while all later occurrences occurs in the context of the loop exit, 'while B'. (cbb 5/80)

Subtopic: data structure traversal up

Quote: with ordered types and generalized for statements, data structure traversal is a high level control structure for the programming language [»abraH12_1977]

Subtopic: loop over states, events, conditions, decision table up

Quote: complex iterations by a selection phase that uses a decision table and an action phase; repeat until exit action [»zimmJA2_1981]
Quote: bystates control form--a for loop over states that select actions; actions may also select states [»zimmJA2_1981]
QuoteRef: zahnCT_1974 ;;172 event driven case statement: until ev. or ev2 or... or evn do so then case evb: sl : ev2: s2 etc. see GVBT3
Quote: it..ti combines loop and conditional constructs by repeatedly executing true guards until a downArrow is found [»parnDL8_1983]
Quote: an alternative command executes exactly one guarded command; a repetitive command executes alternative commands until fail
QuoteRef: martMJ_1974 ;;668 repeat case case-expression of labeled-statement-looping-list exit on labeled-statement-case-list (case-expression returns a lab

Subtopic: universal loop up

Quote: should only have one form of iteration; reduces design complexity [»jackMA_1975]
Quote: program repetitive instructions as First Part, Entry Point, Second Part, Loop Test; place loop count at beginning or end [»turiA3_1951]
QuoteRef: knutDE_1977 ;;167 OJ Dahl: general repetition-- loop: Sl; while B: S2; repeat;
QuoteRef: neelPM_1973 ;;121 generalized do loop DO-THRU end-loop body-before-test WHILE conditional body-after-test end-loop
QuoteRef: grayJC_1973 ;;170 do loops optional preludes and postludes by $(prelude$(body of loop$) postlude$) if neither short form of $$(loop-body$$)
QuoteRef: frieFL1_1974 ;;11 within loops have repeat identifier of loop until %condition% a form !% also exit %identifier of loop%
Quote: only repeat loop at keyword LOOP [»mossCD1_1980]
QuoteRef: grayJC_1973 ;;170 "jumpout" to skip do loop postlude
QuoteRef: chamDD_1971 ;;265 loops where initialize variables and repeat when all of loop is done


Related Topics up

Topic: simple loop (15 items)
Topic: termination of control unit
(22 items)

Updated barberCB 6/04
Copyright © 2002-2008 by C. Bradford Barber. All rights reserved.
Thesa is a trademark of C. Bradford Barber.