Subroutines and Stacks

Noel M. Morris · 1981

Many programs call for an operation to be repeated several times. For example, every traffic light system needs to introduce a time delay between successive light display patterns. If the time delay program is written into the main program each time it is required, even in a simple system, it will take up quite a large amount of the available memory space. Clearly, if the time delay program can be written once only, and ‘called for’ by the main program at appropriate intervals, then not only is the programming effort reduced but also the overall amount of memory space needed for the program is reduced.

Read the paper · More papers on PaperTik