Thursday, 18 June 2015

#10n4 Computer Science - Lesson 47 - Python Challenges 1-8

Lesson Objectives 
LO1 - to review Python knowledge, use of input() and print()
LO2 - to understand data types - int, float and string


Outcomes
Red - You will have completed challenges 1-2
Amber - You will have completed challenges 3-5
Green - You will have completed challenges 6-8


Starter

print() function 
The print function prints information to the screen. 
print (“Hello World”)

input() function 
The input function allows the user to enter information into the computer. name = input("Hi. What's your name? ") print ("Hello, ", name) 

Variables 
A variable is used in a program to store information. In the program above the variable is name. Because the variable is in quotes “” or ‘’, the variable type is called a string.

Main

RED
  • Complete Challenge 1 in the booklet 
  • Complete Challenge 2 in the booklet


AMBER 
  • Complete Challenge 3 in the booklet
  • Complete Challenge 4 in the booklet
  • Complete Challenge 5 in the booklet 
GREEN
  • Complete Challenge 6 in the booklet
  • Complete Challenge 7 in the booklet
  • Complete Challenge 8 in the booklet  

Plenary

Fill in the variable worksheet in your booklet