Home arrow Additional Information arrow Submission Specification

Our Patreons

Diamond Sponsors

Steven & Felix Halim

Reinardus Pradhitya 

Gold Sponsors

--- YOUR NAME HERE ---- 

Silver Sponsors

--- YOUR NAME HERE ----  

Bronze Sponsors

Christianto Handojo

Krzysztof Adamek

Fatima Broom

Amal AugustineTechBuy


Become a patron






Submission specification
Currently, only the submussions via the "Quick Submit" link or the "Submit" icon for each problem is possible. In order to submit your code, just fill in the form and press "submit". Using this form, you don't have to include any special header to the file as everything is handled by the system.

General Specifications:

The program reads the test input from the standard input (stdin) and places the results in the standard output (stdout). This is always the case, regardless on what the problem description says. Every line in the input is guaranteed to be finished by the end-of-line character ('\n').  In a similar way, your program must print an end-of-line character at the end of every line. A correct output with a missing end-of-line character will not be judged as Accepted.

The program doesn't need (in fact, they aren't allowed to) open files or to execute some system calls. Remember: never try to open any file or your program will be judged as wrong.

In order to help some people, the Online Judge defines always the 'ONLINE_JUDGE' symbol while compiling your program. Thus, you can test for it to redirect the input/output to a file except while the Online Judge is testing your program by, for example, using the preprocessor directive #ifdef in C.

Pascal Specifications:

FreePascal compiler seems not to use signals to notify runtime errors, but emits a short text message which merges with your program outputs. So, if you have a Runtime Error, you might receive a Wrong Answer error instead. We know this is a problem, but we cannot focus on it right now.

As a reference, we provide a sample Pascal code

C/C++ Specifications:

Don't assume that any header file (stdio.h, stdlib.h, math.h, etc) is going to be included by default. Please, include all the headers that you actually need.

The use of dangerous or deprecated functions is discouraged. We don't judge as Compile Error a submission using those functions, but you use them under your own risk. For example, the gets function can cause a runtime error even if fairly used. Please, use fgets instead.

As a reference, we provide a sample C code

Java Specifications:

The Java programs submitted must be in a single source code (not .class) file. Nevertheless, you can add as many classes as you need in this file. All the classes in this file must not be within any package.

All programs must begin in a static main method in a Main class.

Do not use public classes: even Main must be non public to avoid compile error.

 Use buffered I/O to avoid time limit exceeded due to excesive flushing.

As a reference, we provide a sample Java code


If you have any question or consider that some information is missing, please contact us.