How to create an OFFLINE judge to test programs locally

I want to build a judge in my PC to test a few programs, whose test datas I have. Please help me!


I don’t know what os you’re using nor what format do the tests have so I made a bash script example.

The program has two arguments:

  1. number of testcases
  2. the name of program you want to test

And it assume that the testcases names’ have the following format:

  • Input files in1, in2, in3, … , inn
  • Expected output files out1, out2, out3, … , outn

It is very simple and could be developed infinitely (time limits, web interface etc.), but it has the basic functionality that every judge have, run the program with the given input and compare its output with the expected.

Hope it helps :slight_smile: And have nice time building your judge!

1 Like

@sanroylozan i dont know bash. can you write a similar code for building a judge in dev-c++?