Description:
my fault, fixing auto full score to properly handle subtask case
Commit status:
[Not Reviewed]
References:
Comments:
0 Commit comments 0 Inline Comments
Unresolved TODOs:
There are no unresolved TODOs
Add another comment

r346:d02b70f6c474 - - 1 file changed: 7 inserted, 2 deleted

@@ -173,8 +173,13
173 173 #just set the full score to the total number of test case
174 174 #it is not perfect but works on most normal use case
175 175 def import_full_score(dirname)
176 - in_file = Dir["#{dirname}/*.in"]
177 - full_score =in_file.length * 10
176 + num = 0
177 + loop do
178 + num += 1
179 + in_file = Dir["#{dirname}/#{num}*.in"]
180 + break if in_file.length == 0
181 + end
182 + full_score = (num - 1) * 10
178 183 @problem.full_score = full_score
179 184 @problem.save
180 185 return "\nFull score is set to #{full_score}."
You need to be logged in to leave comments. Login now