0% found this document useful (0 votes)
34 views10 pages

Algorith M& Flowchar T

Uploaded by

Austin
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views10 pages

Algorith M& Flowchar T

Uploaded by

Austin
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 10

/

ALGORITH
M&
FLOWCHAR
T
</ALGORITHM>

● An Algorithm is an important tool that is used to give the solution to a problem in step by step manner

/DEFINITION

An algorithm is a finite set of instruction in a specific sequence, which is


followed accomplished a particular task. It is written in simple English

/CHARACTERISTICS

- It is a general-purpose tool, which is language and hardware independent


- It makes it easy to understand the program logic
- Identification of error is easier
- A program can be easily written from an algorithm
- Since it is written in simple English it can be understood by everyone

Copyright
©austinmakasare22@gmail.com
</PROPERTIES OF ALGORITHM>

1. FINITENESS : The algorithm should terminate after a finite number of


steps.

2. DEFINITENESS : Each instruction must be clear and unambiguous.

3. EFFECTIVENESS : Every instruction must be sufficiently basic, that it


can be carried out by a Person using only pencil and
paper.

4. INPUT : The algorithm must accept zero or more quantities, which are
externally supplied.

5. OUTPUT : It should produce at least one desired output.

(Every algorithm most satisfy the give properties)

Copyright
©austinmakasare22@gmail.com
</EXAMPLE OF ALGORITHM>
> Calculate the area of a circle > To check if a number is positive
by taking radius input or negative
Step 1: Start.
Step 1: Start
Step 2: Input value of radius.
Step 2: input number
Step 3: Calculate area using formula
Step 3: If number < 0 then
area = 3.142 x radius x radius
Display “Number is negative”
Step 4: Display value of area
Else
Step 5: Stop Display “Number is positive”

Step 4: Stop

Copyright ©austinmakasare22@gmai
</EXAMPLE>
>To find sum of first N positive
numbers, i.e,1+2+3+……+N.
Step 6: increment value of num by 1.
Step 1: Start
Step 7: add num to sum and store result in sum,
i.e sum = sum + num
Step 2: Input value of N
Step 8: If Num < = N, then Go
Step 3: Assign 0 to sum
to step 6
Step 4: assign 1 to sum
Step 9: Display value of sum
Step 5: Add num to sum and store
Step 10: stop
result in sum
i.e sum = sum + num

Copyright
©austinmakasare22@gmail.com
</FLOWCHART>

An algorithm is a written form of the solution to a problem. However , it can get very lengthy and Complicated. A
flowchart is a diagrammatic way of specifying the solution. It is a program Design tool in which standard graphical
symbols are used to represent the logical flow of data.

/DEFINITION

A flow chart is a diagrammatic or pictorial representation of an algorithm.

/CHARACTERISTICS

- since it is a pictorial representation, it can be understood very easily


- It is very easy to identify errors
- Process and data flow can be easily traced for all possible cases
- It is a general purpose tool and it is language independent
- It is very easy to write a program from the flowchart

Copyright
©austinmakasare22@gmail.com
</FLOWCHART SYMBOLS>

Indicates start and stop of Indicates a condition and


the process two or more alternatives

Terminal
Decision
Indicates an input or
output task Shows direction of flow

Input/Output
Flow lines

Contains Arithmetic or
Assignment task Used for calling an
external module

Process
Module call

Copyright
©austinmakasare22@gmail.com
</FLOWCHART SYMBOLS>

It is used to connect different


flowlines or used to show
continuity of flowchart on separate
pages.

Connector

__________
| |
Indicates a block of
| |
statements
| |
| __________|
Multiway selection

Block Allows selection of one out of


many alternatives

Copyright
©austinmakasare22@gmail.com
</EXAMPLES OF FLOWCHART>
> flowchart to check if a number is even or
> flow chart to calculate area of circle
odd
START
START

Read num
INPUT RADIUS

Is
Area = 3.142 x radius x radius Num % 2 = 0

Display num
DISPLAY is odd
Display num
is even
STOP
STOP

Copyright
©austinmakasare22@gmail.com
</DIFFERENCE BETWEEN>

> ALGORITHM < > FLOWCHART <


- An algorithm is a set of ordered - Flowchart is graphical representation
instructions in simple English of algorithm
language designed to solve certain
problems - Less detailed but easy to understand
by everyone
- Algorithm is more detailed but
difficult to understand by - Standard symbols are used for specific
everyone task

- Specific instructions are used - Flowcharts are created later on using


algorithms
- Algorithm get created first
- Branching and looping is easy to show
- Branching and looping is difficult to
show - Big problems can be managed easily

Copyright
©austinmakasare22@gmail.com

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy