Skip to content

Commit 166241a

Browse files
committed
Add Grading-Students
1 parent 35e7241 commit 166241a

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

HackerRank/Grading-Students.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# Grading Students
2+
# https://www.hackerrank.com/challenges/grading/problem
3+
4+
def gradingStudents(grades):
5+
for index,grade in enumerate(grades):
6+
if grade%5 >= 3 and grade >= 38:
7+
grades[index] += 5-grade%5
8+
return grades
9+
10+
# Testcases
11+
# 73 67 38 33 - 75 67 40 33
12+
13+
# Status - Passed

0 commit comments

Comments
 (0)