Structured programming and subroutines (procedures and functions)

EasyMediumHard
123456789101112131415161718192021222324252627282930313233343536373839404142
Question 30
Easy

In the control software for an autonomous deep-sea submersible, a local variable named densityOffset is declared within the subroutine calculatePressureDepth.

Explain what is meant by a local variable, referencing its scope and lifetime.

[2]

Structured programming and subroutines (procedures and functions) Questions

  1. GCSE
  2. /Computer Science
  3. /Structured programming and subroutines (procedures and functions)