Contest control system

During the contest, teams will submit proposed solutions to the contest problems to the judges using the Kattis contest control system. The team manual for Kattis can be found here.

Compilation of submissions

Source files submitted to the judges will be compiled using the following command line arguments for the respective language:

  • C (GCC 10.3.0)
    gcc -g -O2 -std=gnu17 -static {files} -lm
  • C++ (GCC 10.3.0)
    g++ -g -O2 -std=gnu++20 -static {files}
  • Java 11 (OpenJDK, Java 11.0.11)
    javac -encoding UTF-8 -sourcepath . -d . {files}
  • Python 3 (PyPy3 7.3.3, Python 3.6.12)
    pypy3 -m py_compile {files}
  • Kotlin (1.4.21)
    kotlinc -d . {files}

The "{files}" in the above commands represents the list of source files from the submission which will actually be compiled. Files with the following suffixes (and only files with these suffixes) will be submitted to the compiler:

  • For C submissions: .c
  • For C++ submissions: .cc. .C, .cpp, .cxx, or .c++
  • For Java submissions: .java
  • For Python submissions: .py
  • For Kotlin submissions: .kt

Execution of submissions

For each language, if the above compilation step is successful then the submission will be executed as follows:

  • For C/C++: the executable file generated by the compiler will be executed to generate the output of the submission.
  • For Java: the compiled main class will be executed using the following command:
    java -Dfile.encoding=UTF-8 -XX:+UseSerialGC -Xss128m -Xms1856m -Xmx1856m
  • For Python 3: the main source file will be executed by the PyPy3 interpreter to generate the output of the submission.
  • For Kotlin: the compiled main class will be executed using the following command:
    kotlin -Dfile.encoding=UTF-8 -J-XX:+UseSerialGC -J-Xss128m -J-Xms1856m -J-Xmx1856m

Execution as described above will take place in a "sandbox". The sandbox will allocate 2GB of memory; the entire program, including its runtime environment, must execute within this memory limit. For interpreted languages (Java, Python, and Kotlin) the runtime environment includes the interpreter (that is, the JVM for Java/Kotlin and the Python interpreter for Python).

The sandbox memory allocation size will be the same for all languages and all contest problems. For Java and Kotlin, the above command shows the stack size and heap size settings which will be used when the program is run in the sandbox. For C, C++, and Python, the heap and stack sizes are limited only by the total amount of memory available in the sandbox.

Partners