refactoring print_students method, using while instead of each_with_index
indeting output with center method