Details
-
Type: Improvement
-
Status: Resolved
-
Priority: Minor
-
Resolution: Obsolete
-
Affects Version/s: Current Version
-
Fix Version/s: Far Future
-
Component/s: OIOIOI
-
Labels:None
Description
It could be useful for contest admins to list the submissions with shortest execution time, for example if they could sort submissions by their maximal execution time among all test cases / sum of execution times on all test cases. Admins could also want to see the submissions with the shortest source code (in bytes) or see only the submissions which scored the maximal amount of points.
1. score - I believe we shall allow db ordering for scores. I think it
shall be solved by adding db_order method to ScoreValue, returning
int, which could be used for sorting. Then, add a field to Submission
which on save() will be updated from score.db_order. Obviously some
scores may not implement db_order, ex. always returning None from
db_order().
I know we currently use Very Flexible Design For Scores, but it shall
not prevent us from implementing some useful features where it is
possible.
BTW, i cannot think of score which could not be mapped homomorphically to int...
2. execution time - O.o it could be done pretty easily - you may annotate qs in admin, then sort by annotated. However, we shall decide if we want it, as it costs a bit db work.
3. source code length - it seems ok to me to add source_length int field to ProgramSubmission and update it on save()
Caution: 1 and 3 needs not only scheme, but also data migration
^ review pls