Our brand new solo games combine with your quiz, on the same screen

Correct quiz answers unlock more play!

New Quizalize solo game modes
10 questions
Show answers
  • Q1
    What is meant by subroutine?
    A subroutine is a section of code within a large program that will perform a single task
    It's a storage location in memory
    Looping a section of code until a condition is true
    A subroutine is a section of code within a large program that will perform multiple tasks
    45s
    3.2.10
  • Q2
    What is an advantage of using subroutines?
    Subroutines makes it more difficult to track the program flow
    Saves the programmers time because code can be re-written easily
    Saves the programmers time because code can be reused as it's been written and tested
    Check whether a condition is true
    45s
    3.2.10
  • Q3
    Why would you want to use local variables?
    They're easier to see that the value has not changed
    Saves the programmers time because code can be reused as it's been written and tested
    They're easier to track the changes
    Local variables are better because you can change the value in any part of the program
    45s
    3.2.10
  • Q4
    How do you start a subroutine in pseudocode?
    SUBROUTINE name (parameters) ENDSUBROUTINE
    SUBROUTINE name (parameters) SUBROUTINE
    SUBROUTINE
    SUB END
    45s
    3.2.10
  • Q5
    What is the purpose of this subroutine?
    Question Image
    To add the meal and drinks together to work out the total cost
    This is not an example of a subroutine
    To add the meal together to work out the total cost
    It's a calculator
    45s
    3.2.10
  • Q6
    What is the purpose of parameters?
    They pass through variables from the subroutine to the main program
    Parameters do not return a value back to the main program
    They pass through variables from the main program to the subroutine
    It's job is it return a value back to the main program
    45s
    3.2.10
  • Q7
    Here is an example of a subroutine. How do you call the subroutine and output it to the screen?
    Question Image
    RETURN number
    OUTPUT remainder()
    remainder()
    OUTPUT number
    45s
    3.2.10
  • Q8
    Which of these creates a subroutine called levelUp that will increase the score by 10 and level by 1? The correct subroutine must pass the score and level through as parameters.
    levelUp() level = level + 1 score = score + 10 ENDSUBROUTINE
    SUBROUTINE levelUp(score, level) level = level + 1 score = score + 10 ENDSUBROUTINE
    SUBROUTINE levelUp() level = level + 1 score = score + 10 ENDSUBROUTINE
    SUBROUTINE levelUp(score, level) level = level + 1
    120s
    3.2.10
  • Q9
    What code will declare a new local variable called number with a value of 5 in this subroutine?
    Question Image
    number <-- 5
    numberGenerator(number)
    (number)
    RETURN number
    60s
    3.2.10
  • Q10
    What is the difference between a function and procedure?
    A function passes through variables from the main program to the subprogram, whereas a procedure does not
    A procedure passes through variables from the main program to the subprogram, whereas a function does not
    A function returns a value back to the main program whereas procedure does not
    A procedure returns a value back to the main program whereas procedure does not
    60s
    3.2.10

Teachers give this quiz to your class