work on subfunctions - 21 tests pass