Avatar

Avatar
MrsAnderson

Monday 31 October 2016

8wbCP2 P5 901 Python Lesson 1

To be able to understand and use basic Python Syntax

Starter: Find or discuss definitions for "Python" and "Syntax"
Why should we learn to code?

Create a new folder in Sites, called Year 8 Python.
Open Python 3.4 (Idle) from your Start Menu.
Then go to File, New.  This will open up a new file. 
Follow the teacher's instructions, discussing what the code means and should do. 



Link to Teacher's Slides



Development - now you have a basic understanding. What might we be asking the programming to do?  



print ("hello world")

name = input ("What is your name?")
happy = input ("Hello " + name + " are you feeling happy today?")

if happy == "yes":
print("That's good, I'm so glad you're happy!")
elif happy == "no":
print("Oh no, poor you, I'm sorry to hear that!")
else:
print("Please don't talk goggledygook!")




Deeper Learning - 
Once you have the above programming to work. Add to your program so you can have a conversation with the computer (stick to yes and no answers for now!)


Create an account at www.codecademy.com (use your Wildern email account)
Complete the first Python course called ‘Python Syntax’

Moving on... review our Learning Objective. What can you do now that you couldn't do at the beginning of the lesson? What do you now understand? What questions do you still have?

No comments:

Post a Comment