Regularity
From Maze
(Difference between revisions)
(copy/paste error) | (Beginning of structured programming section) | ||
| Line 74: | Line 74: | ||
===Structured programming=== | ===Structured programming=== | ||
| + | |||
| + | Dijkstra's comments about GOTO were part of a movement toward programming languages that are designed for structured programming. Dijkstra himself would later take the idea further in his Notes on Structured Programming. Instead of viewing a program as line after line of text, structured programming practices involve seeing a program as an abstract set of tasks to be completed. Each of these tasks can be completed independent of one another; one section of the program can be written without worrying about how it is going to reference other sections because they share a common method of moving data between them. At a high level, programmers do not need to worry about how each function will work, they just know that it will and this knowledge allows them to plan their code strategically. Dijkstra compared this model to a string of pearls: | ||
| + | |||
| + | <blockquote>One of the metaphors in which I find myself thinking about the program structure envisaged regards the programs as a necklace, strung from individual pearls. We have described the program in terms of levels and each level contained "refinements" of entities that were assumed available in higher levels. […] I use the term "pearl" for [individual functions].</blockquote> | ||
| + | |||
===OOP=== | ===OOP=== | ||
===Recursion=== | ===Recursion=== | ||
