Hero background

Conditional Statements

Technology • 45 • 20 students • Created with AI following Aligned with National Curriculum for England

Download now

Free PDF · we'll email you a copy

Technology
45
20 students
27 January 2026

Teaching Instructions

This is lesson 6 of 10 in the unit "Programming Fundamentals with Python". Lesson Title: Conditional Statements in Python Lesson Description: Learn to write programs that make decisions using if, elif, and else statements. Explore comparison operators and logical reasoning in programming.

Overview

This 45-minute lesson deepens students’ understanding of programming decisions through conditional statements in Python, focusing on if, elif, and else constructs. It is lesson 6 of 10 in the "Programming Fundamentals with Python" unit and adheres strictly to the National Curriculum for England (Key Stage 3 - Years 7 to 9) Computing Programme of Study.


Curriculum References

  • National Curriculum Computing Programme of Study:
    • Use two or more programming languages, at least one of which is textual, to solve a variety of computational problems
    • Design, use and evaluate computational abstractions that model the state and behaviour of real-world problems and physical systems
    • Use logical reasoning to explain how some simple algorithms work and to detect and correct errors in algorithms and programs
    • Apply coding techniques to control or simulate physical systems and processes
  • Subject Content (Key Stage 3 Computing):
    • Develop their capability, creativity and knowledge in programming by solving problems through the design and manipulation of variables, sequences, selections (conditionals), and iterations
    • Understand how conditional and Boolean logic statements control the flow of a program

Learning Objectives

By the end of this lesson, students will be able to:

  1. Understand and explain the purpose of conditional statements (if, elif, else) in Python programming (NC KS3 - programming concepts).
  2. Use comparison operators (==, !=, <, >, <=, >=) and logical operators (and, or, not) to build decision-making structures (NC KS3 - logical reasoning).
  3. Write and debug Python programs that use multiple conditional statements to produce different outputs based on user input or variable conditions (NC KS3 - computational abstractions).
  4. Employ computational thinking by designing simple algorithms with nested or chained conditionals to solve problems efficiently (NC KS3 - problem solving techniques and algorithms).

Prior Knowledge

  • Basic Python syntax: variables, input/output, simple print statements
  • Introduction to programming concepts in previous lessons (lessons 1-5)
  • Understanding of Python data types: integers, strings, booleans

Resources Needed

  • Computers with Python IDE or an online Python environment
  • Whiteboard and markers
  • Printed handouts with example code snippets and exercises
  • Projector to demonstrate live coding

Lesson Structure

Starter (5 minutes)

  • Engage with a quick quiz:
    Pose 3 quick true/false or multiple-choice questions to recap on basic Python commands and highlight the need for decision-making in programs. For example:
    • “What would the program output if we only had print statements?”
    • “Can a program decide between two different actions on its own?”
  • Goal-share: Briefly outline today’s objective to explore program flow control using conditionals.

Introduction & Teacher Modelling (10 minutes)

  • Introduce conditional statements if, elif, and else:
    • Explain syntax and interactive flow
    • Use a real-world analogy (e.g. deciding whether to take an umbrella if it’s raining)
  • Demonstrate comparison operators and logical operators with simple examples:
temperature = 10
if temperature < 0:
    print("Freezing weather")
elif temperature < 20:
    print("Cool weather")
else:
    print("Warm weather")
  • Show tracing the program flow and output depending on different inputs.

Guided Practice (15 minutes)

  • Paired coding task:
    Distribute a worksheet with several incomplete programs requiring students to insert correct conditional statements to complete the logic. Example prompts:
    • A program that asks the user for their age and decides if they are a child, teenager, or adult.
    • Using logical operators to check if a username and password input are both correct before granting access.
  • Circulate and support, prompting students to verbalise the reasoning behind each conditional statement used.

Independent Task (10 minutes)

  • Students create a short Python program that:
    • Prompts the user for weather conditions (rainy, sunny, snowy) and temperature (numeric input).
    • Uses if, elif, and else to suggest appropriate clothing or activities, incorporating at least one logical operator (and or or).
  • Encourage them to test multiple inputs and debug as needed.

Plenary & Assessment (5 minutes)

  • Exit Ticket: Each student writes briefly:
    • What is the difference between if and elif?
    • What logical operator would you use to check if two conditions are both true?
  • Use this to gauge understanding and address common misconceptions in the next lesson.

Differentiation

  • Support: Provide syntax scaffolds and flowcharts for students who struggle with structuring conditionals.
  • Challenge: Ask more able students to include nested conditionals or combine multiple logical operators for more complex decision making.

Cross-Curricular Links

  • Mathematics: Logical reasoning and relational operators draw directly on maths concepts of comparison and Boolean algebra.
  • English: Developing precise syntax and terminology when explaining code helps literacy and communication skills.

Extension Ideas/Homework

  • Write a program that simulates a simple game decision tree using nested conditionals.
  • Research and present how decision-making structures are used in real-world software (e.g., GPS route selection, weather apps).

Teacher Reflection Points

  • Were students able to grasp nested and multiple conditionals clearly?
  • Did the logical operators and, or, not get accurate application?
  • Assess the balance between conceptual explanation and practical coding time — is it improved in future lessons?

This targeted, interactive lesson plan marries National Curriculum standards with engaging, age-appropriate activities, supporting all learners to develop foundational Python programming skills essential for computational thinking and digital literacy.

Create Your Own AI Lesson Plan

Join thousands of teachers using Kuraplan AI to create personalized lesson plans that align with Aligned with National Curriculum for England in minutes, not hours.

AI-powered lesson creation
Curriculum-aligned content
Ready in minutes

Created with Kuraplan AI

Generated using gpt-4.1-mini-2025-04-14

🌟 Trusted by 1000+ Schools

Join educators across United Kingdom