[testlib] Checkers

Правка en2, от Zlobober, 2015-06-09 16:36:43

Checker is a program that should be written when task allows more than one correct solution. Although it seems that it is very easy to write checker, there are lots of important technical details that are easy to forget if you don't use a special library like testlib.h.

A common convention is that a checker should be a program taking three command-line arguments: the testdata filename, the participant output filename and the jury answer filename. Checker should read the contents of the input, output and answer, decide whether participant answer is correct (and optimal being compared to the jury's answer if there can be unoptimal answer in this task) and return one of several pre-defined verdicts:

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en10 Английский Zlobober 2015-06-09 20:25:45 25
en9 Английский Zlobober 2015-06-09 20:24:31 0 (published)
en8 Английский Zlobober 2015-06-09 20:22:02 644
en7 Английский Zlobober 2015-06-09 20:03:43 1134
en6 Английский Zlobober 2015-06-09 19:54:32 72
en5 Английский Zlobober 2015-06-09 19:51:19 7104
en4 Английский Zlobober 2015-06-09 17:34:25 4655 Tiny change: 'blem). |\n| Wrong ' -
en3 Английский Zlobober 2015-06-09 16:37:33 198
en2 Английский Zlobober 2015-06-09 16:36:43 120
en1 Английский Zlobober 2015-06-09 16:36:29 730 Initial revision (saved to drafts)