I moved the introduction back into the main script; it has so many flow-control points.  I want all the comprehensible stuff in the main script, and all the complicated backend stuff in the functions.  I also modified the getinput function to allow specifying specific types.  Specifically, it sanitizes integer inputs.  I added a litte more age-related logic, and made a setenv function and tried to fold all the startup-related script environment stuff down to one incomprehensible line at the beginning.