Remove intentation issues and rename temp hash to group_by_length