solution to hw3, recording/persisting data