You are on page 1of 39

Algorithms and Flowcharts

Mr. Lorie M. Cagalitan, Mr. Charles Hanz Bautista, Ms. Glyrhiz Marhiel
A. Tabamo and Mr. Eyeryl Jun Tano
Faculty, Institute of Computer Applications

1
Understanding Algorithm
• Within the context of business logic, the set of rules or statements on
how the application implements the business rules, and how the
application should behave between the user and database must be
well define.
• Algorithm must be build to describe the execution of the business
logic.

2
What is Algorithm?
• A set of well-defined rules or procedures for solving a problem in a
finite number of steps, or providing an output from a specific set of
inputs. Usually implemented as a computer program.
• A finite set of well-defined rules for the solution of a problem in a
finite number of steps.
• instructions for how to solve a problem. [4]

3
Understanding Algorithm
• To make a computer do anything, you have to write a computer
program. To write a computer program, you have to tell the
computer, step by step, exactly what you want it to do. The computer
then "executes" the program, following each step sequentially, to
accomplish the end goal. [5]
• When you are telling the computer what to do, you also get to
choose how it's going to do it. That's where computer algorithms
come in. The algorithm is the basic technique used to get the job
done

4
Understanding Algorithm
• Algorithm is very easy to understand but building an algorithm for a
given problem is another thing.

5
Understanding Algorithm
• Three (3) things to consider in creating an algorithm.
• Input, Process, Output

Input Process Output

Data Information

Data – facts and figures (numerical representation of an entity)


Information – a processed data.

• Each algorithm should have these 3 elements.


• Algorithm should be detailed enough.

6
Understanding Algorithm
• Condition and Loops may be required in the process.
• Best algorithm considerations
• less time to execute.
• less resources.

7
Algorithm: Real World Example
• Recipe.
• Procedures (Enrolment, Registration, Clearance, etc.)
• Route (Courier, Mailman, Taxi, etc.)
• Operating Manual.
• Searching
• Sorting
• File Compression

8
Exercise: Write down the algorithms for the
following problems
• Converting Kilo to Pound
• Determining if an inputted score is passing or not given the total
number of items and the passing percentage.
• Getting the maximum out of 3 inputted numbers.

9
Understanding Algorithms in Business
• Algorithms have been at the heart of most successful corporate
empires in the world [1]
• Coca-Cola boasts of its “secret recipe” – its own version of an
algorithm.

10
Understanding Algorithms in Business
• Given that the 55,000 trucks in UPS’ American fleet make 16 million
deliveries daily, the potential for inefficient routing is enormous. By
applying telematics and algorithms, UPS saves its drivers 85 million
miles a year, resulting in annual savings of $2.55 billion.

11
Understanding Algorithms in Business
• Google is another organization that
has mastered data and algorithms.
• In 2002, their search algorithm earned
them half a billion dollars a year.
That’s already good money by any
standard, but their investments into
algorithms are really paying off now.
• The latest version of their search
algorithm now makes half a billion
dollars in just three days. In other
words, they’re now collecting the
same amount of revenue in less than
one percent of the time it used to take
[2]

12
Understanding Algorithms in Business
• Failure to implement algorithms in your organization is likely to see
you lose a competitive advantage to your rivals.
• Example: Nokia
• “We didn’t do anything wrong but somehow, we lost” [3]
• Inferiority of the Symbian Operating System.
• Arrogance among top-level managers.
• Lack of vision.

13
Algorithm Application in Business: Customer
Interaction
• Data leverage by data science and data mining.
• What does the vast amount data collected by businesses actually
mean?
• Algorithms can be used to make business processes clear, more
unique, and ensure right solutions for customers based on what they
want.
• Example: Amazon suggestions based on algorithm driven from
customer behavior.

14
Algorithm Application in Business: Slim-line a
workforce
• Automation
• One of the biggest expenses in most organization is human resource.
• Reduced with algorithms able to take on many tasks typically
assigned to workers.
• The idea is that companies can become smaller (human resource) and
more profitable.

15
Algorithm Application in Business: Real-time
accuracy
• Recognizing patterns and trends to react and adjust is vital for a
business’s success.
• Critical for stock market, foreign exchange, crypto-currency, etc.

16
Algorithm Application in Business: Processing
Data
• Algorithm play role in almost every fast and efficient data process.
• Example: Telematics (method of monitoring and harvesting data from
any moving asset)
• Google Maps and the like.

17
Assignment
•Select a legitimate business national or international.
•Identify vital algorithms that are being maximized towards
profitability.
•Discuss how the algorithms works and how is it distinct from
its competitors.
•Class presentation may be required.

18
What is a Flowchart?
•A flowchart is a graphical representation that illustrates the
sequence of operations of how a data or a transactional
process works [6].
•The flowchart is a means of visually presenting the flow of
data through a data processing operation.

19
Understanding Flowchart
•Flowcharts play a vital role in the programming of a problem
and are quite helpful in understanding the logic of
complicated and lengthy problems.
•Low-level implementation of flowchart

20
Understanding Flowchart
•In business, it is a method of visually documenting the stages
involved in performing a certain business procedure called a
process flow.
•High-level implementation of flowchart.

21
Understanding Flowchart

BENEFITS LIMITATIONS
• Communication: Flowcharts are • Complex logic: Sometimes, the
better way of communicating the program logic is quite complicated.
logic of a program to all concerned. In that case, flowchart becomes
• Effective analysis: With the help of complex and clumsy.
flowchart, problem can be analyzed • Modifications: If modifications are
in more effective way. required the flowchart may require
• Proper documentation: Program re-drawing completely.
flowcharts serve as a good program • Reproduction: As the flowchart
documentation, which is needed for symbols cannot be typed,
various purposes. reproduction of flowchart becomes
• Proper Debugging: The flowchart a problem.
helps in debugging process.
22
Flowchart Symbols
•Microsoft Office Insert Shapes

23
Flowchart Symbols
Terminator
• Terminators show the start and
stop points in a process. When
used as a Start symbol,
terminators depict a trigger
action that sets the process
flow into motion [3].
• Used with the terms “Start” and
“End”.
Flowchart Symbols
Data
• Input or Output operation.
• Specify if its an “Input” or
“Output”.
Flowchart Symbols
Process
• Show a Process or action step.
This is the most common
symbol in both process
flowcharts and process maps
[3].
Flowchart Symbols
Decision
• Indicates a question or branch
in the process flow. Typically, a
Decision flowchart shape is
used when there are 2 options.
• Making decisions and
branching. Its a two-way
decision process [3].
Flowchart Symbols
Flow Line
• Flow line connectors show the
direction that the process flows
[3].
Flowchart Symbols
Connector
• This symbol is typically small
and is used as a Connector to
show a jump from one point in
the process flow to another.
Connectors are usually labeled
with capital letters (A, B, C,..) to
show matching jump points.
They are handy for avoiding
flow lines that cross other
shapes and flow lines [3].
Guidelines in Flowcharting
• The usual direction of the flow of a procedure or system is from left to
right or top to bottom.
Guidelines in Flowcharting
• Only one flow line should come out from a process symbol.
Guidelines in Flowcharting
• Only one flow line should enter a decision symbol, but only two flow
lines should leave the decision symbol.
Guidelines in Flowcharting
• Only one flow line is used in conjunction with terminal symbol.
Guidelines in Flowcharting
• If the flowchart becomes
complex, it is better to use
connector symbols to reduce
the number of flow lines.
Avoid the intersection of
flow lines if you want to
make it more effective and
better way of
communication.
Examples of Flowchart
•Low-level implementation of flowchart
Start

Computing for the Voltage given the Current Input I


and Resistance
Input R
1.) Input I as Current value.
2.) Input R as Resistance value..
3.) Let V be equal to the product of I & R. V=I*R
4.) Output the value of V as the Voltage.
Output
V

Stop

35
Examples of Flowchart
•Low-level implementation of flowchart
Start

Conversion from Kilo to Pounds. Input K

1.) Input a Kilo value store to K.


2.) Let Pound be equal to K * 2.2. Pound = K * 2.2
3.) Output Pound value.
Output
Pound

Stop

36
Examples of Flowchart
Start
•Low-level implementation of flowchart
Input A

Determining whether a number is Val = A modulus


ODD or EVEN. 2

1.) Input a number call it A. If


T Val F
2.) Divide A by 2
3.) If the remainder is none zero, then <> 0
output “the number is odd”,
otherwise Output Output
output “the number is even”. “Odd” “Even”

Stop
37
Examples of Flowchart
•High-level implementation of flowchart.

38
References:
1. https://www.arrkgroup.com/thought-leadership/guide-to-algorith
mic-business-an-introduction/
2. https://blog.growthinstitute.com/exo/algorithms
3. https://medium.com/multiplier-magazine/why-did-nokia-fail-81110
d981787
4. https://slate.com/technology/2016/02/how-to-teach-yourself-abou
t-algorithms.html
5. https://computer.howstuffworks.com/what-is-a-computer-algorith
m.htm
6. https://www.edrawsoft.com/Flowchart-Definition.php

39

You might also like