First six functions finished and tested.