Replace clock with process_time. Submit works.
This commit is contained in:
@@ -214,7 +214,7 @@ def output(input_file, solver_file):
|
|||||||
|
|
||||||
solution = ''
|
solution = ''
|
||||||
|
|
||||||
start = time.clock()
|
start = time.process_time()
|
||||||
try:
|
try:
|
||||||
solution = pkg.solve_it(load_input_data(input_file))
|
solution = pkg.solve_it(load_input_data(input_file))
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
@@ -224,7 +224,7 @@ def output(input_file, solver_file):
|
|||||||
print(str(e))
|
print(str(e))
|
||||||
print('')
|
print('')
|
||||||
return 'Local Exception =('
|
return 'Local Exception =('
|
||||||
end = time.clock()
|
end = time.process_time()
|
||||||
|
|
||||||
if not (isinstance(solution, str) or isinstance(solution, unicode)):
|
if not (isinstance(solution, str) or isinstance(solution, unicode)):
|
||||||
print('Warning: the solver did not return a string. The given object will be converted with the str() method.')
|
print('Warning: the solver did not return a string. The given object will be converted with the str() method.')
|
||||||
|
|||||||
Reference in New Issue
Block a user