Inter-House Standings
Compute Inter-House Sports Day standings.
Input:
- Line 1: number of result lines,
n - Next
nlines: each a house name and the points it scored in one event, e.g.Red 10(a house may appear more than once, once per event it competed in)
Output: each house's total points across all events, one per line as House: total, sorted from highest total to lowest. If two houses are tied, break the tie alphabetically by house name.
There is no single required approach — decide how to accumulate and sort the data yourself.
main.py
Loading editor…
Console
Run your code to see output here.
Hints