first pass at solution