0% found this document useful (0 votes)
48 views

Representation of Algorithm and Flow Chart

An algorithm is a step-by-step process to solve a problem using well-defined instructions, while a flowchart provides a graphical representation of an algorithm using standard symbols. A flowchart breaks down an algorithm visually into a block diagram using boxes, arrows, and other symbols to show the steps and order of operations. Creating a flowchart allows for an intuitive understanding of an algorithm compared to describing it through prose alone.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
48 views

Representation of Algorithm and Flow Chart

An algorithm is a step-by-step process to solve a problem using well-defined instructions, while a flowchart provides a graphical representation of an algorithm using standard symbols. A flowchart breaks down an algorithm visually into a block diagram using boxes, arrows, and other symbols to show the steps and order of operations. Creating a flowchart allows for an intuitive understanding of an algorithm compared to describing it through prose alone.
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

REPRESENTATION OF ALGORITHM AND FLOW CHART

Algorithm and flowchart are two types of tools to explain the process of a program. This
page extends the differences between an algorithm and a flowchart, and how to create
a flowchart to explain an algorithm in a visual way.

Algorithms and flowcharts are two different tools used for creating new programs,
especially in computer programming. An algorithm is a step-by-step analysis of the
process, while a flowchart explains the steps of a program in a graphical way.

Definition of Algorithm

To write a logical step-by-step method to solve the problem is called algorithm, in other
words, an algorithm is a procedure for solving problems. In order to solve a
mathematical or computer problem, this is the first step of the procedure. An algorithm
includes calculations, reasoning and data processing. Algorithms can be presented by
natural languages, pseudo code and flowcharts, etc.

Definition of Flowchart

A flowchart is the graphical or pictorial representation of an algorithm with the help of


different symbols, shapes and arrows in order to demonstrate a process or a program.
With algorithms, we can easily understand a program. The main purpose of a flowchart
is to analyze different processes. Several standard graphics are applied in a flowchart:

• Terminal Box - Start / End

• Input / Output

• Process / Instruction

• Decision
• Connector / Arrow

The graphics above represent different part of a flowchart. The process in a flowchart
can be expressed through boxes and arrows with different sizes and colors. In a
flowchart, we can easily highlight a certain element and the relationships between each
part.

Difference between Algorithm and Flowchart

If you compare a flowchart to a movie, then an algorithm is the story of that movie. In
other words, an algorithm is the core of a flowchart. Actually, in the field of computer
programming, there are many differences between algorithm and flowchart regarding
various aspects, such as the accuracy, the way they display, and the way people feel
about them. Below is a table illustrating the differences between them in detail.

Algorithm Flowchart
It is a procedure for solving problems. It is a graphic representation of a process.
The process is shown in step-by-step The process is shown in block-by-block information
instruction. diagram.
It is complex and difficult to understand. It is intuitive and easy to understand.
It is convenient to debug errors. It is hard to debug errors.
The solution is showcased in natural
The solution is showcased in pictorial format.
language.
It is somewhat easier to solve complex
It is hard to solve complex problem.
problem.
It costs more time to create an algorithm. It costs less time to create a flowchart.

What is an Algorithm?

An algorithm is a set of well-defined instructions in sequence to solve a problem.


Qualities of a good algorithm

1. Input and output should be defined precisely.

2. Each step in the algorithm should be clear and unambiguous.

3. Algorithms should be most effective among many different ways to solve a problem.

4. An algorithm shouldn't have computer code. Instead, the algorithm should be written in
such a way that, it can be used in different programming languages.

The word Algorithm means “a process or set of rules to be followed in calculations or


other problem-solving operations”. Therefore Algorithm refers to a set of
rules/instructions that step-by-step define how a work is to be executed upon in order to
get the expected results.

It can be understood by taking an example of cooking a new recipe. To cook a new


recipe, one reads the instructions and steps and execute them one by one, in the given
sequence. The result thus obtained is the new dish cooked perfectly. Similarly,
algorithms help to do a task in programming to get the expected output.

The Algorithm designed are language-independent, i.e. they are just plain instructions
that can be implemented in any language, and yet the output will be the same, as
expected.
What are the Characteristics of an Algorithm?

As one would not follow any written instructions to cook the recipe, but only the
standard one. Similarly, not all written instructions for programming is an algorithm. In
order for some instructions to be an algorithm, it must have the following characteristics:
• Clear and Unambiguous: Algorithm should be clear and unambiguous. Each of
its steps should be clear in all aspects and must lead to only one meaning.
• Well-Defined Inputs: If an algorithm says to take inputs, it should be well-defined
inputs.
• Well-Defined Outputs: The algorithm must clearly define what output will be
yielded and it should be well-defined as well.
• Finite-ness: The algorithm must be finite, i.e. it should not end up in an infinite
loops or similar.
• Feasible: The algorithm must be simple, generic and practical, such that it can be
executed upon will the available resources. It must not contain some future
technology, or anything.
• Language Independent: The Algorithm designed must be language-independent,
i.e. it must be just plain instructions that can be implemented in any language, and
yet the output will be same, as expected.

EXAMPLE –
TO ADD TWO NUMBERS
1. START
2. ENTER TWO NUMBERS
3. ADD NUMBERS(C= A+B)
4. PRINT RESULT
5. STOP

You might also like