Created
February 23, 2017 06:39
-
-
Save rjshekar90/3ef2d452d89a245ea6abba9a88fa2d2c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Hackerrank ------ Finding the percentage | |
if __name__ == '__main__': | |
n = int(raw_input()) | |
student_marks = {} | |
for _ in range(n): | |
line = raw_input().split() | |
name, scores = line[0], line[1:] | |
scores = map(float, scores) | |
student_marks[name] = float(sum(scores)/len(scores)) | |
query_name = raw_input() | |
print ("%0.2f"%student_marks[query_name]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment