Warning
This page is located in archive.

Brute

Solutions to homework and contest semester project are submitted to Brute where they are automatically checked and evaluated (the research semester project is also submitted to Brute, however it is evaluated manually by the corresponding lab teacher). General information about the Brute

  • Supported programming lanugages: C++ and Python3. The Brute tries to automatically detect the language of submitted source codes by checking the file suffixes (cpp for C++, py for Python3).
  • Compiled programs must be able to run on GNU/Linux operating system.
  • All programs are linked with Gurobi 11 solver and with the exceptions specified below, the source codes are expected to be independent on other than standard libraries.
  • Source codes with multiple files has to be submitted as .zip archives.
  • If your program exits with non-zero status, you will be notified about this. Usually, non-zero status is returned when your program crashes.

Details about input, output and command line arguments of your compiled programs are provided in the corresponding assignment PDFs.

Important: the time limits are scaled by the programming language in the homework assignments. However, this is not true for the contest semester project, i.e. all programming languages have the same time-limit in the contest semester project.

From now on, assume that $ROOT_DIR is the root directory with your submitted source codes.

C++ details

Requirements:

  1. all source files must reside in $ROOT_DIR (subdirectories are not allowed)
  2. all source files have either cpp or h suffix
  3. one of cpp files must contain main() function

Source codes are compiled with G++ version 13.2, with flags -std=c++11 -O2 -march=native -pthread .

Python3 details

Requirements:

  1. source file $ROOT_DIR/main.py is the top file that will be run and therefore it must exist
  2. source file $ROOT_DIR/main.py begins #!/usr/bin/env python3
  3. all Python files must be encoded in UTF-8
  4. if you want to use Gurobi library, import gurobipy module

Source codes are run with cpython interpreter, version 3.11. Additional allowed libraries:

  • numpy

Common issues

  • Incorrectly taking the command line arguments. In C++ and Python, argv array contains the name of your program on the 0-th index, whereas in Java this name is not included.
  • Not sanitizing your output file. Make sure that the content in the output file matches exactly the format specified in the assignment handouts, i.e., no extra spaces, no extra blank lines etc.
  • Using text encoding format other than UTF-8 in the source codes. We recommend using UTF-8 for maximum compatibility.
  • When receiving time limit as a command line argument (e.g., in semester project), not keeping a reserve time for outputting the solution into the output file. Keep in mind that the time limit you receive is the same time limit as in UploadSystem after which your program is killed. Therefore, it is possible that your program is killed before it outputs the solution into the output file. Different languages and different solution sizes might require different reserve time, so you should experiment to find the right amount.
courses/ko/upload_system.txt · Last modified: 2024/02/16 11:44 by medjaku1