refactor puzzle_06
refactor