Primary Symbol's :
Programmers use Primary Symbols to show the insructions or actions needed to solve the problem presented in the algorithm.
With these symbols, it is possible to represent all the three structured programming constructs - Sequence, Decision and Repetition Statements.
- Sequence Statements.
- Selection (Decision) Statements.
- Looping (Repetition) Statements.
1.) Sequence Statement's :
Sequence Statements represent a series of actions that must continue a linear order. Although the actions represented in the Sequence Symbols may be very complex, such as input or output operation, the logic flow must enter the symbol at the top and flow out at the bottom.
Sequence Symbols do not allow any decisions or flow changes within the symbol.
Flowcharts use four Sequence Symbol's :
- Input | Output
- Module call
- Compound Statement
|Assignment Statement||Module Call|
|Input/Output Statement||Compound Statement|
Null Statement :
It is worth nothing that do nothing is a valid statement. It is a sequence statement, since it can not change the flow direction of a program. There is no symbol for a null statement, it is simply a flow line.
Assignment Statement :
the Assignment Statement is shown using a rectangle. Within the assignment symbol, the assignment operator is shown as a left-pointing arrow. At right side of the arrow is an expression whose value must be stored in the variable at the left side.This is shown in the following figure.
|Variable <-- Expression|
Input/Output Statements :
a parallelogram shows any input or output, such as reading from a keyboard or writing on the system console. For Ex:- an algorithm that reads the values of two variable from the keyboard and then writes their values on the screen in the reverse order as shown in the figure.