Get the input file and check it is valid.
Renamed algorithm to a better name.

Previous name described the user or program, not the algorithm.
Parse input file and extract settings.

Parse the input file through a series of modes.  Start by parsing settings,
and continue until the first blank line.  For known settings, store the parsed
value (after an equals sign) in the appropriate variable.  Skip unknown keys.

At the moment, simpply print out lines when in the input mode, and abort
parsing if in an unknown mode.