First attempt at implementing the homework assignment.  Both functions
were implemented and appear to work.