A-level Computing/AQA/Problem Solving, Programming, Data Representation and Practical Exercise/Skeleton code/2011 Exam/Section C

From Wikibooks, open books for an open world
Jump to: navigation, search

Discussion of the code[edit]

Potential questions[edit]

Validation[edit]

  • List the Erroneous, Extreme and Typical Data for a manual bowling die:
  • List the Erroneous, Extreme and Typical Data for a manual appeal die:

Variables[edit]

  • Give the name of the identifier of a Constant
  • Give the name of the identifier of a global variable
  • Give the identifier of a local variable
  • Note the identifier of an array:
  • Why might we not want to store an average score as an integer?

Loops[edit]

  • Give the name of a stepper variable used in a loop?
  • Give the name of a fixed variable used in a loop?
  • Give the name of a follower used in a loop?
  • Give the name of a most recent holder used in a loop?

Sub Routines[edit]

  • Write down a function declaration used in the program
  • Write down a function call used in the program
  • Write down a procedure declaration used in the program
  • Give the name of a parameter used in a procedure
  • Explain the difference between using byRef and byVal
  • Why is Byref used in the ResetTopScores sub routine?
  • Write down where a return value for a function is assigned:

Trace Tables[edit]

  • Construct a trace table for the ResetTopScores procedure when passed the following data:
Maxsize Count TopScores
1 2 3 4
name score name score name score name score
4 Peter 23 Michael 65 Aubrey 24 Marea 89