Programming with Python: first steps · Lesson 3 of 3

Making decisions: if, elif and else

Today you will

  • Compare values with ==, !=, <, >, <= and >=.
  • Follow which branch of an if, elif and else runs.
  • Combine conditions with and, or and not.

Before you start: Variables and arithmetic, from the first two lessons.

Opening your exercise book…

Practice

Marked as you go. Get 75% right to complete the lesson.

Getting your desk ready…

Build status · Flash Infinity AI™ is a trademark of AI-Flash Inc.. WorldClass is not affiliated with, approved or accredited by any exam board, curriculum provider or university unless a page says so.