UVa 10258

From Algorithmist
Jump to navigation Jump to search

Straightforward solution, just read the problem specs carefully.

Use string streams to parse the input, they're fast enough for this problem. You need to handle whitespace in random places.

Define a struct that represents a team and write a comparator for it. Note that you sort by solved, then time, then team number. Use the STL sort algo.