publish solutions
This commit is contained in:
@@ -15,3 +15,19 @@ students = {
|
||||
'Histoire': 78
|
||||
}
|
||||
}
|
||||
|
||||
name = input("Entrez le nom de l'étudiant : ")
|
||||
if name in students:
|
||||
total = 0
|
||||
print(f"Notes de {name}:")
|
||||
for i in students[name]:
|
||||
note = students[name][i]
|
||||
total += note
|
||||
print(i, ":", note)
|
||||
print(f"Moyenne de {name} : {total/len(students[name])}")
|
||||
|
||||
else:
|
||||
print("L'étudiant", name, "n'existe pas.")
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user