[go: up one dir, main page]

0% found this document useful (0 votes)
14 views8 pages

RRC EA9 Module02

The document discusses an LSPU self-paced learning module on algorithms and flowcharts for a computer applications course. It provides an introduction to the topics, including definitions of algorithms as sequences of steps to solve problems and flowcharts as visual representations of algorithmic processes. The module outlines learning outcomes and objectives and provides guidance on key concepts like algorithm development and flowchart rules and symbols to help students understand and apply algorithms and flowcharting techniques.

Uploaded by

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

RRC EA9 Module02

The document discusses an LSPU self-paced learning module on algorithms and flowcharts for a computer applications course. It provides an introduction to the topics, including definitions of algorithms as sequences of steps to solve problems and flowcharts as visual representations of algorithmic processes. The module outlines learning outcomes and objectives and provides guidance on key concepts like algorithm development and flowchart rules and symbols to help students understand and apply algorithms and flowcharting techniques.

Uploaded by

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

Republic of the Philippines

Laguna State Polytechnic University


ISO 9001:2015 Certified
Province of Laguna
Level I Institutionally Accredited

LSPU Self-paced Learning Module (SLM)

Course EA9- Computer Applications in AB Engineering


Sem/AY First Semester/2023-2024
Module No. 2.1
Lesson Title Algorithm and Flowchart
Week
1 weeks (week 2 )
Duration
Date
This lesson will discuss the Algorithm and Flowchart. Students will also receive an
Description Seatwork and access to the computer laboratory in this course so they can
of the comprehend the Algorithm and Flowchart.
Lesson

Learning Outcomes
Intended
Learning Students should be able to meet the following intended learning outcomes:
Outcomes  • Able to apply algorithm and flowcharting technique in program and project
design

At the end of the lesson, students should be able to:


Targets/  Understand the key concepts and principles covered in the lesson
 Identify the different rules in using shapes in flowchart.
Objectives
 Apply the theory or concept to analyse a real-world scenario.

Student Learning Strategies


LSPU SELF-PACED LEARNING MODULE: TECHNOLOGY FOR TEACHING AND LEARNING
Prepared by: Richmond R. Corda, PABE
Republic of the Philippines
Laguna State Polytechnic University
ISO 9001:2015 Certified
Province of Laguna
Level I Institutionally Accredited

Lecture Guide
Algorithm and Flowchart

INTRODUCTION
Intelligence is one of the key characteristics which differentiate a human being
from other living creatures on the earth. Basic intelligence covers day to day problem solving and
making strategies to handle different situations which keep arising in day to day life. One person
goes Bank to withdraw money. After knowing the balance in his account, he/she decides to with
draw the entire amount from his account but he/she has to leave minimum balance in his account.
Here deciding about how much amount he/she may with draw from the account is one of the
examples of the basic intelligence. During the process of solving any problem, one tries to find the
necessary steps to be taken in a sequence. In this Unit you will develop your understanding about
problem solving and approaches.
PROBLEM SOLVING
Can you think of a day in your life which goes without problem solving?
Answer to this question is of course, No. In our life we are bound to solve problems. In our day to
day activity such as purchasing something from a general store and making payments, depositing
fee in school, or withdrawing money from bank account. All these activities involve some kind of
problem solving. It can be said that whatever activity a human being or machine do for achieving a
specified objective comes under problem solving. To make it clearer, let us see some other
examples.
Example1:
If you are watching a news channel on your TV and you want to change it to a sports channel, you
need to do something i.e. move to that channel by pressing that channel number on your remote.
This is a kind of problem solving.
Example 2:
One Monday morning, a student is ready to go to school but yet he/she has not picked up those
books and copies which are required as per timetable. So here picking up books and copies as per
timetable is a kind of problem solving.
Example 3:
If someone asks to you, what is time now? So seeing time in your watch and telling him is also a
kind of problem solving.
Example 4:
Some students in a class plan to go on picnic and decide to share the expenses among them. So
calculating total expenses and the amount an individual have to give for picnic is also a kind of
problem solving.

Now, broadly we can say that problem is a kind of barrier to achieve


something and problem solving is a process to get that barrier removed by performing some
sequence of activities

Here it is necessary to mention that all the problems in the world can not be
solved. There are some problems which have no solution and these problems are called Open
Problems.

LSPU SELF-PACED LEARNING MODULE: TECHNOLOGY FOR TEACHING AND LEARNING


Prepared by: Richmond R. Corda, PABE
Republic of the Philippines
Laguna State Polytechnic University
ISO 9001:2015 Certified
Province of Laguna
Level I Institutionally Accredited

ALGORITHM
Algorithm can be defined as: “A sequence of activities to be processed for
getting desired output from a given input.” Webopedia defines an algorithm as: “A formula or set of
steps for solving a particular problem. To be an algorithm, a set of rules must be unambiguous and
have a clear stopping point”. There may be more than one way to solve a problem, so there may be
more than one algorithm for a problem. Now, if we take definition of algorithm as: “A sequence of
activities to be processed for getting desired output from a given input.” Then we can say that:

1. Getting specified output is essential after algorithm is executed.


2. One will get output only if algorithm stops after finite time.
3. Activities in an algorithm to be clearly defined in other words for it to be unambiguous.

Before writing an algorithm for a problem, one should find out what is/are the inputs to the
algorithm and what is/are expected output after running the algorithm. Now let us take some
exercises to develop an algorithm for some simple problems: While writing algorithms we will use
following symbol for different operations:

‘+’ for Addition


‘-’ for Subtraction
‘*’ for Multiplication
‘/’ for Division and
‘ ’ for assignment. For example A X*3 means A will have a value of X*3
Example
Problem 1: Find the area of a Circle of radius r. Inputs to the algorithm: Radius r of the Circle.
Expected output: Area of the Circle

Algorithm: Step1: Read\input the Radius r of the Circle


Step2: Area PI*r*r // calculation of area
Step3: Print Area

FLOWCHART
The flowchart is a diagram which visually presents the flow of data through
processing systems. This means by seeing a flow chart one can know the operations performed and
the sequence of these operations in a system. Algorithms are nothing but sequence of steps for
solving problems. So a flow chart can be used for representing an algorithm. A flowchart, will
describe the operations (and in what sequence) are required to solve a given problem. You can see
a flow chart as a blueprint of a design you have made for solving a problem.

For example suppose you are going for a picnic with your friends then you
plan for the activities you will do there. If you have a plan of activities then you know clearly when
you will do what activity. Similarly when you have a problem to solve using computer or in other
word you need to write a computer program for a problem then it will be good to draw a flowchart
prior to writing a computer program. Flowchart is drawn according to defined rules.

Flowchart Symbols

LSPU SELF-PACED LEARNING MODULE: TECHNOLOGY FOR TEACHING AND LEARNING


Prepared by: Richmond R. Corda, PABE
Republic of the Philippines
Laguna State Polytechnic University
ISO 9001:2015 Certified
Province of Laguna
Level I Institutionally Accredited
There are 6 basic symbols commonly used in flowcharting of assembly language Programs:
Terminal, Process, input/output, Decision, Connector and Predefined Process. This is not a
complete list of all the possible flowcharting symbols, it is the ones used most often in the structure
of Assembly language programming.

General Rules for flowcharting


1. All boxes of the flowchart are connected with Arrows. (Not lines)
2. Flowchart symbols have an entry point on the top of the symbol with no other entry points. The
exit point for all flowchart symbols is on the bottom except for the Decision symbol.
3. The Decision symbol has two exit points; these can be on the sides or the bottom and one side.
4. Generally a flowchart will flow from top to bottom. However, an upward flow can be shown as
long as it does not exceed 3 symbols.
5. Connectors are used to connect breaks in the flowchart. Examples are:
• From one page to another page.
• From the bottom of the page to the top of the same page.

LSPU SELF-PACED LEARNING MODULE: TECHNOLOGY FOR TEACHING AND LEARNING


Prepared by: Richmond R. Corda, PABE
Republic of the Philippines
Laguna State Polytechnic University
ISO 9001:2015 Certified
Province of Laguna
Level I Institutionally Accredited
• An upward flow of more then 3 symbols
6. Subroutines and Interrupt programs have their own and independent
flowcharts.
7. All flow charts start with a Terminal or Predefined Process (for interrupt
programs or subroutines) symbol.
8. All flowcharts end with a terminal or a contentious loop.
Flowcharting uses symbols that have been in use for a number of years to represent the type of
operations and/or processes being performed. The standardised format provides a common
method for people to visualise
problems together in the same manner. The use of standardised symbols makes the flow charts
easier to interpret, however, standardizing symbols is not as important as the sequence of activities
that make up the process.

EXAMPLE 1.
FLOWCHART FOR DISTANCE SENSOR

Distance reading

LSPU SELF-PACED LEARNING MODULE: TECHNOLOGY FOR TEACHING AND LEARNING


Prepared by: Richmond R. Corda, PABE
Republic of the Philippines
Laguna State Polytechnic University
ISO 9001:2015 Certified
Province of Laguna
Level I Institutionally Accredited
EXAMPLE 2
Find the area of a circle of radius r.

LSPU SELF-PACED LEARNING MODULE: TECHNOLOGY FOR TEACHING AND LEARNING


Prepared by: Richmond R. Corda, PABE
Republic of the Philippines
Laguna State Polytechnic University
ISO 9001:2015 Certified
Province of Laguna
Level I Institutionally Accredited
EXAMPLE 3
Flowchart for the problem of printing even numbers between 9 and 100:

Engaging Activities
Quiz 1
Laboratory 02

Learning Resources

Prepared by:

Richmond R. Corda, PABE

LSPU SELF-PACED LEARNING MODULE: TECHNOLOGY FOR TEACHING AND LEARNING


Prepared by: Richmond R. Corda, PABE
Republic of the Philippines
Laguna State Polytechnic University
ISO 9001:2015 Certified
Province of Laguna
Level I Institutionally Accredited
Part Time Instructor, LSPU-Siniloan Campus

This module is for educational purpose only. Under section Sec. 185 of RA 8293, which states,
“The fair use of a copyrighted work for criticism, comment, news reporting, teaching
including multiple copies for classroom use, scholarship, research, and similar purposes is
not an infringement of copyright. The unauthorized reproduction, use, and dissemination of
this module without joint consent of the authors is strictly prohibited and shall be
prosecuted to the full extent of the law, including appropriate administrative sanctions, civil,
and criminal”

LSPU SELF-PACED LEARNING MODULE: TECHNOLOGY FOR TEACHING AND LEARNING


Prepared by: Richmond R. Corda, PABE

You might also like