LAB(1)
LAB(1)
FLOWCHART
LAB(1)
Eng:Mona Ahmed Ali Abdullah 2
Introduction
• This section establishes the foundation for starting the
solution of simple problems by using a computer.
Introduction
• Notation of Algorithm:
An algorithm must satisfy the following criteria:
• Input: there is certain number (0 or more) of quantity which
are externally supplied.
• Output: at least one quantity is produced.
• Finiteness: for all cases the algorithm should terminate after
a finite number of steps.
• Definiteness: each instruction must be clear and
unambiguous to avoid any misinterpretation.
Ex: an operation such as “subtract 2 or 7 from 9” is not
permitted due to the ambiguity caused by it.
• Effectiveness: every instruction must be sufficiently basic,
that it can in principle be carried out by any person.
Eng:Mona Ahmed Ali Abdullah 4
Program Flowchart
Definition
Block diagram that uses predefined symbols and
interconnecting line to represent the logic and sequence of
specific program operation.
Eng:Mona Ahmed Ali Abdullah 7
Terminal Processing
(start/end) (calculation and
storing
operation)
Input/output Decision
operation (conditional
branching)
Eng:Mona Ahmed Ali Abdullah 8
Flow line
Subprogram
(direction)
call
connection
comment
Eng:Mona Ahmed Ali Abdullah 9
,y
Eng:Mona Ahmed Ali Abdullah 16
x,y,z
Eng:Mona Ahmed Ali Abdullah 18