Refactor U Week6 Problem Set