100% satisfaction guarantee Immediately available after payment Both online and in PDF No strings attached 4.6 TrustPilot
logo-home
Lecture notes

Class notes Computer science

Rating
-
Sold
-
Pages
3
Uploaded on
24-11-2023
Written in
2023/2024

Flowcharts and Pseudocodes









Whoops! We can’t load your doc right now. Try again or contact support.

Written for

Study
Unknown
Module
Unknown

Document information

Uploaded on
November 24, 2023
Number of pages
3
Written in
2023/2024
Type
Lecture notes
Professor(s)
E b
Contains
All classes

Subjects

Content preview

Week 5 Computer Systems Lecture: Flowchart and Pseudocode 13.02.23

Video

 First part of flowchart is to input a number
 Then a second number
 Then the flowchart will ask a question
 The flowchart will then branch the output
 Make sure you know what shapes should be used in the flowchart
 Pseudocode is an alternative way to represent the sequence in an algorithm
 The instructions match up to the flow chart e.g. INPUT number 1

Flowcharts

 Diagram that represents workflow or process
 Can also be defined as a diagrammatic representation of an algorithm, a step-by-step
approach to solving a task
 X = Price, Y = Price 2
 If the price of product 1 is bigger than the price of product 2, print X. Otherwise print Y, then
stop
 If X and Y are the same price, you will get an error. You have to do another branch e.g. if X
=Y, you need to print X and Y are the same
 You can also write if X=Y or if X>Y and this can go to one branch
 The flowchart shows the steps as boxes of various kinds, they are ordered by connecting the
boxes with arrows
 This diagrammatic representation illustrates a solution model to a given problem
 Flowcharts are used in analysing, designing, documenting or managing a process or program
in various fields

Example of customer credit

 Need to add Start and Finish
 Buy product - Credit form  Order form Credit check  If the credit check is good 
Review accounts receivable balance. If credit check is not good  back to sales call
 You can only have two arrows from every statement e.g. yes/no, true/false, 1/2
 If you need more than two arrows, you need to add another statement

Flowchart (Loop statement While/do while)

 Between the input and output there is a processing stage
 While – you have a condition (true or false) e.g. while I = < 5 and you want to change. Check
the task, then check
 Do while – I < 5, check the file, then do the task
 For – you need 3 things: initial value, last value and increment or decrement value
 Loop – the arrow loops back to the start. Do while – the loop stems from the condition,
While loop – the arrow stems from the task

Over 60 working example Python

 And is the same as multiplying e.g. 0 and 1 is 1
 If the condition is false you will not get anything in the output
 0 or 1 is 1
£7.99
Get access to the full document:

100% satisfaction guarantee
Immediately available after payment
Both online and in PDF
No strings attached

Get to know the seller
Seller avatar
cpaine

Get to know the seller

Seller avatar
cpaine The University of Salford
View profile
Follow You need to be logged in order to follow users or courses
Sold
0
Member since
2 year
Number of followers
0
Documents
12
Last sold
-

0.0

0 reviews

5
0
4
0
3
0
2
0
1
0

Recently viewed by you

Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their exams and reviewed by others who've used these revision notes.

Didn't get what you expected? Choose another document

No problem! You can straightaway pick a different document that better suits what you're after.

Pay as you like, start learning straight away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and smashed it. It really can be that simple.”

Alisha Student

Frequently asked questions