In: Computer Science
Week 1 - Map and Critique a Control Flow.
Initial Post
Describe and map a sample of a control flow.
Group Discussion Critique the control flow of two other submissions.
This should include why it is either an effective or ineffective control flow.
If effective, describe why. Examples would be its thoroughness of structures, substantial interactions and flows, etc.
If ineffective, describe why. Examples would be missing steps, flow is incorrectly lined, etc.
In computer science, control flow (or flow of control) is the order in which individual statements, instructions or function calls of an imperative program are executed or evaluated. The emphasis on explicit control flow distinguishes an imperative programming language from a declarative programming language.
Within an imperative programming language, a control flow statement is a statement that results in a choice being made as to which of two or more paths to follow. For non-strict functional languages, functions and language constructs exist to achieve the same result, but they are usually not termed control flow statements.
A set of statements is in turn generally structured as a block, which in addition to grouping, also defines a lexical scope.
Interrupts and signals are low-level mechanisms that can alter the flow of control in a way similar to a subroutine, but usually occur as a response to some external stimulus or event (that can occur asynchronously), rather than execution of an in-line control flow statement.
At the level of machine
In computer science, control-flow analysis (CFA) is a
static-code-analysis technique for determining the control flow of
a program. The control flow is expressed as a control-flow graph
(CFG). For both functional programming languages and
object-oriented programming languages, the term CFA, and
elaborations such as k-CFA, refer to specific algorithms that
compute control flow.[dubious – discuss]
For many imperative programming languages, the control flow of a
program is explicit in a program's source code. As a result,
interprocedural control-flow analysis implicitly usually refers to
a static analysis technique for determining the receiver(s) of
function or method calls in computer programs written in a
higher-order programming language.For example, in a programming
language with higher-order functions like Scheme, the target of a
function
call may not be explicit: in the isolated expressionlanguage or
assembly language, control flow instructions usually work by
altering the program counter. For some central processing units
(CPUs), the only control flow instructions available are
conditional or unconditional branch instructions, also termed
jumps.