year 7 lesson 1 introduction to programming

10
INTRODUCTION TO PYTHON LE S SON 1

Upload: tmoncrieff

Post on 23-Jun-2015

1.372 views

Category:

Education


2 download

DESCRIPTION

Year 7 - Lesson 1 - Intro to Python

TRANSCRIPT

Page 1: Year 7 lesson 1   introduction to programming

INTR

ODUCTION T

O

PYTH

ON

L ES

SO

N 1

Page 2: Year 7 lesson 1   introduction to programming

LEARNING OBJECTIVE

Understand and be able to use basic Python syntax.

Page 3: Year 7 lesson 1   introduction to programming

LESSON OUTCOMES

I can identify the different computer programming languages that I use …

I can use IDLE in Python …

I can write and run a program using Python …

Page 4: Year 7 lesson 1   introduction to programming

STARTER – 5 MINS

1.Open up a text editor such as Notepad.

2.Write a list of all the apps, programs and applications you have used so far today.

3.Be ready to share your ideas with the class.

Learning Outcome I can identify the different computer programming languages that I use … I can use IDLE in Python … I can write and run a program using Python …

Page 5: Year 7 lesson 1   introduction to programming

USING PYTHON …

To open Python, click the following:

1. Use the Python Help menu to find out what an IDLE is.

2. What does IDLE stand for?

Learning Outcome I can identify the different computer programming languages that I use … I can use IDLE in Python … I can write and run a program using Python …

Page 6: Year 7 lesson 1   introduction to programming

MINI PLENARY

Jim uses an IDLE to create a program.

Think of two tools in an IDLE that can help Jim when creating the program.

Learning Outcome I can identify the different computer programming languages that I use … I can use IDLE in Python … I can write and run a program using Python …

Page 7: Year 7 lesson 1   introduction to programming

WRITING YOUR FIRST PROGRAM

In a new Python shell copy the following

code:

print ("What is your name?")

firstname = input()

print ("Hello,",firstname)

Learning Outcome I can identify the different computer programming languages that I use … I can use IDLE in Python … I can write and run a program using Python …

Page 8: Year 7 lesson 1   introduction to programming

SYNTAX ERRORS

In a new Python Shell, copy the lines of code below:

Learning Outcome I can identify the different computer programming languages that I use … I can use IDLE in Python … I can write and run a program using Python …

Page 9: Year 7 lesson 1   introduction to programming

SYNTAX ERRORS EXPLAINED …

If you have copied the code correctly your IDLE should look like this:

Syntax error messages point out a problem with the program.

Speech marks, colons, brackets, apostrophes and spelling words have to be just right.

Learning Outcome I can identify the different computer programming languages that I use … I can use IDLE in Python … I can write and run a program using Python …

Page 10: Year 7 lesson 1   introduction to programming

PLENARY

A syntax error can occur when

writing a program.

1. What is meant by a syntax error, give an example.

Learning Outcome I can identify the different computer programming languages that I use … I can use IDLE in Python … I can write and run a program using Python …