An algorithm is a well-defined sequence of mathematical operations

Computer technology is based on the principle of sequential execution of mathematical operations. By virtue of this, there is a need to compile programs that in a given order perform some specific sequence of actions. Since programs can be huge and cumbersome, a specialist often faces the need for graphical (visual) preparation of a work plan - an algorithm.

Algorithm is




An algorithm is a clear absolute record of the sequence of mathematical operations necessary to complete a computer task. It can also be noted that it is a sequence of step-by-step implementation of the initial input data into the final result. The fact is that the goal of any program is to take sequential actions: interrogate the user (input the source data), perform specified actions with the data, and output the result.

The beginning and ending block of the algorithm is depicted in the diagram as an oval and has one output and one input, respectively. Data input and output blocks - in the form of a parallelogram. Blocks of mathematical operations are represented as rectangles and also have one input and one output.





() . . .

- . . , – .

Branching algorithm is




A branching algorithm is a description of a given sequence of actions, which includes checking the data for compliance with a given condition. The result of such a check can be either compliance of the data being checked with the given condition or non-compliance. And depending on the result, either one further sequence of actions is performed, or another.

The helper algorithm is




The check block is depicted as a rhombus with one input and two outputs, corresponding to a positive or negative test.

As a rule, the solution of simple problems can be represented as a small block diagram. But if the task assigned to the programmer is large enough, then the algorithm depicted on paper (monitor) can turn into a bulky monster. To simplify the visual image of the sequence of actions, auxiliary structures are used.

– , , , , . .

, , , , .




All Articles