refactor puzzle display code