# Weeks – 01/ 2 Introduction to flowcharts components and psuedocode.

## Presentation on theme: "Weeks – 01/ 2 Introduction to flowcharts components and psuedocode."— Presentation transcript:

Weeks – 01/ 2 Introduction to flowcharts components and psuedocode

1 11 Objectives Have familiarity using Ms.Visio Have a basic concept in designing solution using flowcharts. Have a basic concept in designing solution using pseudo-codes. Have a basic concept in solving problems and write them as pseudo-codes

2 2 Ms Visio Start all programs ms office ms Visio

3 3 Flowchart symbols Terminator START or END symbols to begin or terminate flowchart. Input/Output Data entry or display output program Process Transform data or expression Conditional / Decision Process with selection Preparation Initialize Arrow connection Connector Online connector

4 4 Flowchart Example-1

5 5 Flowchart Example-2

6 6 Exercise (flowchart) 1.Write a letter for your friend by post 2.Calculate employee fee which reads employee name, hours, and hourly rate. 3.Calculate grade a course with formula grade = 30% x Midterm + 20% x Task + 30% x Final+ 20%xQuiz. Input : name of course, Midterm, Quiz, Final, Task

7 7 Exercise (flowchart) 4. Calculating is total of sales by entering the name of goods, quantity, and price. Output : name of goods and total of purchasing. 5. Calculating area and circumference of circle. With input radius. Output : radius, around and area of circle.

9 No.1

10 No. 2

11 No.3

12 Pseudocode Pseudocode is informal form for depict of algorithm like a programming Ianguage. Objective of pseudocode : Easy to read Easy to understand Easy to get an idea

13 Pseudocode Example Send a letter to friend: 1. Write a letter on a paper. 2. Take an envelope. 3. Put a letter in an envelope. 4. Envelope cover use glue. 5. When you remember the address, so writing address at envelope. 6. Otherwise, find in adrress book, then writing address at envelope. 7. Giving stamp on a letter. 8. Bring a letter to the postoffice.

14 Exrcise (write a pseudocode) 1.Calculate employee fee which reads employee name, hours, and hourly rate. 2.Calculate grade a course with formula grade = 30% x Midterm + 20% x Task + 30% x Final+ 20%xQuiz. Input : name of course, Midterm, Task, Final, Quiz 3.Calculating total of sales by entering the name of goods, quantity, and price. Output : name of goods and total of purchasing.

15 Exercise(write a pseudocode) 4. Calculating area and circumference of circle. With input radius. Output : radius, circumference and area of circle. 5. Changing two number one another. Example initialy number1=4, number2=7, after executing its result number1=7, number2=4 6. Write a program to convert a temperature in degrees Fahrenheit to degrees Celcius and Reamur.

16 Answers-1 1.Calculate employee fee which reads employee name, hours, and hourly rate. Data Dictionary Name : string; Hour,rate, Fee : integer; Algorithm Input(Name, Hour) Rate 8000 Fee Hour*Rate