Topics / Algorithm Design and Problem-Solving / Trace Tables (Algorithm Dry Runs)
Trace Tables (Algorithm Dry Runs)
Trace tables are used when performing a dry-run of an algorithm.
This could be an algorithm expressed as a flowchart or pseudocode.
Trace tables record the outputs for a given set of data, allowing the user to compare these to the expected results.
Trace tables also show the values of variables at each stage of the algorithm.
This information helps to identify errors and issues with logic.
If you are unsure of the purpose of an algorithm, trace tables can help with that too.
The documented nature of a trace table should make performing your dry-run easier with less chances of making a mistake.
How to complete a trace table
Watch the video below for a demonstration of how to complete a trace table for a flowchart.