219k views
1 vote
Pleas help with this

Pleas help with this-example-1
User Esote
by
6.6k points

1 Answer

4 votes

Answer:

points = dict(Harris=24, Butler=11, Embiid=31, Simmons=15, Reddick=9, Scott=8, Ennis=7, Marjanovic=4, Bolden=1, McConnell=2)

total_points = 0

highest_scorer = ""

highest_score = 0

for player, score in points.items():

print(player + ": " + str(score) + " points")

total_points += score

if score > highest_score:

highest_score = score

highest_scorer = player

print("Total points: " + str(total_points))

print("Highest scorer: " + highest_scorer + " (" + str(highest_score) + " points)")

User Raven Dreamer
by
6.4k points