Algorithms Cheat Sheet, Study notes of Algorithms and Programming

Algorithms Cheat Sheet. Flowchart Conventions ... Algorithms - is a set of simple instructions that are done in a certain order to solve a problem.

Typology: Study notes

2021/2022

Uploaded on 08/05/2022

dirk88
dirk88 🇧🇪

4.4

(222)

3.1K documents

1 / 3

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Algorithms Cheat Sheet
Flowchart Conventions
Name
Symbol
Usage
Start or Stop/End
Signifies the start or
end of a sequence.
Process
An instruction.
Input/Output
Data received or
sent by a computer.
Decision
A condition which is
either true or false.
Subroutines
Calls a subroutine
Direction of Flow
Connects the
symbols.
pf3

Partial preview of the text

Download Algorithms Cheat Sheet and more Study notes Algorithms and Programming in PDF only on Docsity!

Flowchart Conventions

Name Symbol Usage

Start or Stop/End Signifies the start or end of a sequence. Process An instruction. Input/Output Data received or sent by a computer. Decision A condition which is either true or false. Subroutines Calls a subroutine Direction of Flow Connects the symbols.

Python Syntax

Action Python code

Assign a variable myVariable^ =^42 myOtherVariable = “Hello” Print something print(“This^ will^ be^ printed”) Getting input age^ =^ input(“How^ old^ are^ you?”) if/else if^ age^ >^ 17: print(“You are an adult”) else: print(“You are not an adult yet”) for loop for^ i^ in^ range(0,10): print(i) while loop while(True): print(“hello again”)