› Teaching Materials › Prepare level 7

What is new in this level?

In this level the students learn how to incoprorate maths into their programs. They'll be able to calculate with variables and decimals from now on.

New in this level:

  • Using mathematical symbols: + - * and /
  • Using decimals with a point
  • Using variables in maths
  • Using the = symbol instead of is
  • Slides Present the level, one concept at a time
  • Workbook Exercises to print, away from the screen Work in progress

Common mistakes

Students struggle with quotation marks

What students get wrong

Some students struggle with adding quotation marks or not. If you add quotation marks, the output screen will literally show '5+5'.

print '5 + 5'
How to fix it

In this code the output screen will print '10'.

print 5 + 5

Students struggle with the concept of doing maths with a variable

What students get wrong

Some students will find it hard to do maths with variables. Try to show them very simple examples, like:

age = ask 'How old are you?'
print 'Next year you will be ' age + 1
How to fix it

Or take it a step further like this.

price = 0
print 'Welcome to our burger restaurant'
burger = ask 'Would you like a burger?'
if burger = yes
price = price + 10
drink = ask 'Would you like a drink?'
if drink = yes
price = price + 4
print 'That will be ' price ' euros please'

Students forget the = symbol

What students get wrong

Forgetting to use = instead of is will always be allowed in Hedy, so no problem. If your goal is your students to work towards actual Python or other programming laguages, it is advised to teach your students to use =. If your goal is just to give your students a taste of programming, don't worry about them using = or is.

name is Hedy
How to fix it

the = symbol

name = Hedy

Students use a comma instead of a point in decimal numbers

What students get wrong

In some languages it's custom to use the comma for decimal numbers. In programming languages a point is used, so in Hedy as well.

print 2,5 + 2,5
How to fix it

Use points in decimal numbers

print 2.5 + 2.5