Skip to content
MathsGenie logo
Open app

Course home

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

Subprograms

EasyMedium
123456789101112131415161718192021222324252627282930
Question 21

A programmer is developing an algorithm to calculate booking costs.

booking_fee = 2.50

def calculate_total(ticket_price, quantity):
    subtotal = ticket_price * quantity
    package_total = subtotal + booking_fee
    return package_total

Give the name of a global variable used in this algorithm.

[1]

Subprograms Questions

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