Subprograms

EasyMediumHard
123456789101112
Question 11
Easy

An athletics track design program uses the following sub-program to calculate the total distance of a race in kilometres:

global conversionFactor = 1.609

function calculateTrackLength(laps, lapLengthMiles)
    distanceMiles = laps * lapLengthMiles
    distanceKm = distanceMiles * conversionFactor
    return distanceKm
endfunction

State the name of one local variable used in this sub-program.

[1]

Subprograms Questions

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