2021-04-27 09:30:15 -07:00
|
|
|
def round_scores(student_scores):
|
|
|
|
|
'''
|
2021-08-25 14:06:53 -07:00
|
|
|
:param student_scores: list of student exam scores as float or int.
|
2021-04-27 09:30:15 -07:00
|
|
|
:return: list of student scores *rounded* to nearest integer value.
|
|
|
|
|
'''
|
2021-09-01 02:11:57 -07:00
|
|
|
|
2020-10-19 22:12:29 +05:30
|
|
|
pass
|
|
|
|
|
|
2021-04-27 09:30:15 -07:00
|
|
|
def count_failed_students(student_scores):
|
|
|
|
|
'''
|
2021-08-25 14:06:53 -07:00
|
|
|
:param student_scores: list of integer student scores.
|
2021-04-27 09:30:15 -07:00
|
|
|
:return: integer count of student scores at or below 40.
|
|
|
|
|
'''
|
2021-09-01 02:11:57 -07:00
|
|
|
|
2020-10-19 22:12:29 +05:30
|
|
|
pass
|
|
|
|
|
|
2021-04-27 09:30:15 -07:00
|
|
|
def above_threshold(student_scores, threshold):
|
|
|
|
|
'''
|
|
|
|
|
:param student_scores: list of integer scores
|
|
|
|
|
:param threshold : integer
|
|
|
|
|
:return: list of integer scores that are at or above the "best" threshold.
|
|
|
|
|
'''
|
2021-09-01 02:11:57 -07:00
|
|
|
|
2020-10-19 22:12:29 +05:30
|
|
|
pass
|
|
|
|
|
|
2021-04-27 09:30:15 -07:00
|
|
|
def letter_grades(highest):
|
|
|
|
|
'''
|
2021-08-25 14:06:53 -07:00
|
|
|
:param highest: integer of highest exam score.
|
2021-04-27 09:30:15 -07:00
|
|
|
:return: list of integer score thresholds for each F-A letter grades.
|
|
|
|
|
'''
|
2021-09-01 02:11:57 -07:00
|
|
|
|
2021-04-27 09:30:15 -07:00
|
|
|
pass
|
2021-09-01 02:11:57 -07:00
|
|
|
|
2021-04-27 09:30:15 -07:00
|
|
|
def student_ranking(student_scores, student_names):
|
|
|
|
|
'''
|
|
|
|
|
:param student_scores: list of scores in descending order.
|
|
|
|
|
:param student_names: list of names in descending order by exam score.
|
|
|
|
|
:return: list of strings in format ["<rank>. <student name>: <score>"].
|
|
|
|
|
'''
|
2021-09-01 02:11:57 -07:00
|
|
|
|
2021-04-27 09:30:15 -07:00
|
|
|
pass
|
2021-09-01 02:11:57 -07:00
|
|
|
|
2020-10-19 22:12:29 +05:30
|
|
|
def perfect_score(student_info):
|
2021-04-27 09:30:15 -07:00
|
|
|
'''
|
|
|
|
|
:param student_info: list of [<student name>, <score>] lists
|
|
|
|
|
:return: First [<student name>, 100] found OR "No perfect score."
|
|
|
|
|
'''
|
2021-05-27 18:51:50 -07:00
|
|
|
pass
|