Using the Judging Utilities

The installation and grading works exactly the same way as last year.  To install the utilities:
  1. If you are not already in DOS, open a Command Prompt (or MS-DOS Prompt).
  2. Change to a directory in which you have write access, under which you want the mcpc2003 directory and subdirectories copied.
  3. Put the judge's diskette in drive A: and type "A:\INSTALL".
This will copy the entire floppy disk, creating subdirectories mcpc2003, mcpc2003\TEAM, mcpc2003\JUDGE, mcpc2003\BACK, mcpc2003\NOTES, and directories with each of the individual problems, and make the current directory mcpc2003\TEAM.

All directories mentioned below are relative to the mcpc2003 directory.

To judge a program, make sure the current directory is still TEAM, and then just type
    J L #
where L is the problem letter, and # is the team number as in "j e 12" to grade problem e for team 12.

This batch file will

  1. search the A: drive for a valid source file for problem L,
  2. delete the relevant contents of TEAM in preparation for judging,
  3. copy the source file into TEAM,
  4. make a uniquely named archival copy of the source file in BACK,
  5. copy the correct input file into TEAM,
  6. compile the program,
  7. run the program,
  8. compare the program's output with the correct output, and if they don't match,
  9. allow you to visually compare the two output files.
Instructions will be displayed on the screen, and you can stop the batch file when necessary by pressing Ctrl-C.

In step 8 the files are compared using the diff utility. If the two files are identical it will say so, and otherwise it will show the differences.  The output of diff is fairly clear when it all fits on one screen.  If there are a lot of errors it may be easier to see them in step 9.

Step 9 is necessary if it is not obvious that there are wrong answers, and you need to check for a presentation error.  The batch file uses the LIST program to view both the team's output and the correct output.

Using the list program:

If you want to see both files at once using the LIST program: IMPORTANT NOTE:  SITE SPECIFIC MODIFICATIONS TO THE GRADING UTILITIES

These batch files assume that java.exe and javac.exe are in the execution path and that there is a default installation of Visual Studio .Net 2003 on drive C: to compile C++ and C files. If you are allowing Pascal, you must substitute your own compiler and linker call for the placeholder line in JUDGE\j2.bat

compileLinkPascal %2.pas
where %2.pas is the source file name. If you are using Visual Studio .Net 2003 for C and C++, but put it somewhere other than the default location on drive C:, then you can edit the environment variable set in JUDGE\vcpp.bat. If you are using another compiler, you can modify vcpp.bat or replace both the places it is called in JUDGE\j2.bat, so that C and C++ files are compiled and linked in your environment.

If you modified j2.bat and/or vcpp.bat last year, and they still work, you may use them again this year, as long as that does not mean anyone will be using a 16-bit compiler implementation. If you are reading this before receiving your official packet, and you need to set up for this year, you can obtain last year's j2.bat and vcpp.bat from the judge's disk zip file at http://www.cs.smsu.edu/~mcpc/archives/mcpc2002.zip. If you modify the 2002 JUDGE\j2.bat file and or JUDGE\vcpp.bat, and it works, use it to replace the corresponding files on this year's disk.

Archive of submitted programs

Example:  The 4th time that team 7 has a C++ program for problem E graded on the same computer, the batch file JUDGE\NEXTBACK.BAT is called to copy their source program to
    BACK\7E4.CPP

Browsing in your spare time

All the judges' files are copied by install.bat.  While waiting for the next problem to grade, or even if you do not use the judging utilities at all, you can browse through the problem files and administrative information files by starting a web browser at the local file browse.html in the mcpc2003 directory.


Andy Harrington
Regional Chief Judge: Toolsmith
Loyola University Chicago

Last modified on October 23, 2003 at 4:47 PM.