Skip to content
MathsGenie logo
Open app

Course home

  1. IGCSE
  2. Computer Science Edexcel
  3. Question bank

Subprograms

EasyMedium
123456789101112131415161718192021222324252627282930
Question 2

A programmer has written the following subprogram to calculate the loyalty points earned on a purchase:

def calculate_points(amount_spent, multiplied_tier):
    if multiplied_tier == True:
        points = amount_spent * 2
    else:
        points = amount_spent
    return points

Identify the name of one parameter used in this subprogram.

[1]

Subprograms Questions

  1. IGCSE
  2. /Computer Science
  3. /Subprograms