Download presentation
Presentation is loading. Please wait.
Published byMargrethe Simonsen Modified over 5 years ago
1
Suggested Layout ** Designed to be printed on white A3 paper.
2
P Y T N H O
3
S Y N X T A
4
C H E A T
5
S H E E T
6
Variables
7
x = 5 y = "John" print(x) print(y)
8
For Loops
9
letters = ["a", "b", "c"] for x in letters: print(x)
for x in range(7): print(x)
10
While Loops
11
x = 1 while x < 8: print(i) x += 1
12
If Statement
13
if x > y: print(“y is greater")
elif x == y: print(“x and y are equal") else: print(“x is greater than y")
14
Functions
15
def my_first_function(): print(“This is how to create a function") my_first_function()
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.