Wat is LessonUp
Zoeken
Kanalen
Inloggen
Registreren
‹
Terug naar zoeken
Teach 2.2.1 and 2.2.2
Teach 2.2.1 and 2.2.2
1 / 23
volgende
Slide 1:
Tekstslide
Computing
Upper Secondary (Key Stage 4)
GCSE
In deze les zitten
23 slides
, met
interactieve quizzen
,
tekstslides
en
4 videos
.
Start les
Bewaar
Deel
Printen
Onderdelen in deze les
Teach 2.2.1 and 2.2.2
Slide 1 - Tekstslide
Question the Answer
Can you write the question to these answers!!
Slide 2 - Tekstslide
Three types of programming construct
Slide 3 - Woordweb
Slide 4 - Video
Slide 5 - Video
Slide 6 - Video
Question this Answer --> A value that can change, usually when the program is running
Slide 7 - Open vraag
Slide 8 - Video
So what is this then --> An item of data that will not change during the program execution
Slide 9 - Open vraag
Examples of constants
VAT rate - 20%
Pi - 3.14159265359
Slide 10 - Tekstslide
What maths operators do you know?
Slide 11 - Woordweb
Maths operators
+ - * /
MOD
DIV
Exponential (to the power of)
Slide 12 - Tekstslide
MOD and DIV
DIV works out full divisions
1
0 DIV 3 = 3
(because 3 fits three times)
In python this looks like
10//3
MOD works out remainder after division
10 MOD 3 = 1
(because 1 left after all 3s accounted for)
In python this looks like
10%3
Slide 13 - Tekstslide
So what does that leave 10**2 to do in python?
Slide 14 - Open vraag
Computers are stupid
They don't know what kind of data you are giving it.
It needs to know the format of that data to store it correctly.
These are called datatypes
Slide 15 - Tekstslide
Data types?
Slide 16 - Woordweb
Data Types
Integer
Real
Boolean
Character/String
Slide 17 - Tekstslide
What would you use to store a first name
A
String
B
Real
C
Integer
D
Boolean
Slide 18 - Quizvraag
What would you use to store a phone number
A
String
B
Real
C
Integer
D
Boolean
Slide 19 - Quizvraag
What would you use to store a price of a product?
A
String
B
Real
C
Integer
D
Boolean
Slide 20 - Quizvraag
What would you use to store whether the customer qualifies for a discount?
A
String
B
Real
C
Integer
D
Boolean
Slide 21 - Quizvraag
What would you use to store how many children you have?
A
String
B
Real
C
Integer
D
Boolean
Slide 22 - Quizvraag
Casting
Turning one datatype into another one when coding
EG
x = input("how old are you?")
if
int(x)
>=18:
print("Adult")
Slide 23 - Tekstslide
Meer lessen zoals deze
Y8 Python - Low Ability - If Elif JM
Juni 2023
- Les met
40 slides
Computing
Lower Secondary (Key Stage 3)
Y8 Python
Juni 2022
- Les met
38 slides
Computing
Lower Secondary (Key Stage 3)
Y8 Python
Juli 2022
- Les met
30 slides
Computing
Lower Secondary (Key Stage 3)
Revise 2.2.1 and 2.2.2
September 2023
- Les met
16 slides
Computing
Upper Secondary (Key Stage 4)
GCSE
Python 101: Introduction to Python Programming
September 2023
- Les met
14 slides
Python - Updated
April 2023
- Les met
19 slides
Computing
Lower Secondary (Key Stage 3)
Python - Lesson 2
April 2023
- Les met
21 slides
Computing
Lower Secondary (Key Stage 3)
Introduction to Programming Constructs: Creating a Computer Game with Python
Oktober 2023
- Les met
23 slides