Year 11

Programming 4: Subroutines

Lessons (6)

    In this lesson, we will formalise our definition of a subroutine. We will find out why they are used in programming and we will also learn how to pass values to them.
    1 Slide deck
    1 Worksheet
    1 Quiz
    1 Video
    In this lesson, we will explore how to create our own functions. Functions are a type of subroutine that allow us to return a value. We have used them before when we have used code like print() and input(). We will also explore the difference between a function and procedure.
    1 Slide deck
    1 Worksheet
    2 Quizzes
    1 Video
    In this lesson, we will learn about the scope of variables. When a variable is initialised within a subroutine it cannot be easily accessed and modified by other subroutines. This lesson will teach us about the different levels of scope and show us how to access variables that are initialised within subroutines.
    1 Slide deck
    1 Worksheet
    2 Quizzes
    1 Video
    In this lesson, we will be introduced to a new operator called XOR. We will discover how an XOR works before writing a function to perform the XOR operation.
    1 Slide deck
    1 Worksheet
    2 Quizzes
    1 Video
    In this lesson, we will be introduced to the paradigm: structured programming is programming. This lesson will also demonstrate how we can apply the paradigm to our own programs.
    1 Slide deck
    1 Worksheet
    2 Quizzes
    1 Video
    In this lesson, we will follow the structured programming approach to create our own program.
    1 Slide deck
    1 Worksheet
    2 Quizzes
    1 Video