WHAT PROGRAMMING LIBRARIES CAN I USE? 

You can use all the standard libraries included with the programming language that you are using. For example, this includes the STL (Standard Template Library) of C++ and the java.lang.BigInteger class of Java.

WHAT JUDGMENTS OF THE ONLINE JUDGE CAN I GET? 

When the COJ has judged your submission, you will get a judgment that tells you what is the status of your solution. You can view the verdict on the judgments page. The following judgments are possible:
  • Judging (JDG) : The judge is busy and it can't judge your solution at the moment. Usually you just need to wait for a few seconds.
  • Runtime Error (RTE) : The RTE judgment means that the program sent by the user has crashed during the execution with the judge's secret tests (e.g.: the process was signaled or exited with a status other than 0). In C and C++, the value 0 must be returned from main(). In Java doing something to ensure that the exit status is 0 isn't necessary. Some of the common reasons and their meanings are:
    • ACCESS_VIOLATION - The program tried to read from or write to a address for which it doesn't have the appropriate access.
    • ARRAY_BOUNDS_EXCEEDED - The program tried to access an array element that is out of bounds and the underlying hardware supports bounds checking.
    • FLOAT_DENORMAL_OPERAND - One of the operands in a floating-point operation is denormal. A denormal value is one that is too small to represent as a standard floating-point value.
    • FLOAT_DIVIDE_BY_ZERO - The thread tried to divide a floating-point value by zero.
    • FLOAT_OVERFLOW - The exponent of a floating-point operation is greater than the magnitude allowed by the corresponding type.
    • FLOAT_UNDERFLOW - The exponent of a floating-point operation is less than the magnitude allowed by the corresponding type.
    • INTEGER_DIVIDE_BY_ZERO - The program tried to divide an integer value by zero.
    • INTEGER_OVERFLOW - The result of an integer operation caused a carry out of the most significant bit of the result.
    • STACK_OVERFLOW - The program used up its stack.
  • Invalid Function (IVF) : The IVF judgment means that the program sent by the user tried to do something which isn't allowed on the COJ. This includes the manipulation of file descriptors, opening files, running functions as fork() or exec(), creating threads, sending signals, or basically anything needless to solve the problem. All IVF judgments are examined to detect any attempt to exploit the system, in such case the involved user will be analyzed and banned from the COJ. Please, contact us if you think that an IVF judgment is not correct or "fair".
  • Time Limit Exceeded (TLE) : The TLE judgment means that the program sent by the user ran for too much time. When the time limit is exceeded, the program is terminated. The output produced isn't inspected in this case, so getting TLE doesn't mean that the program produced the correct output, only that it didn't exit in time.
  • Output Limit Exceeded (OLE) : The program sent by the user tried to write too much information. This usually occurs if it goes into an infinite loop. Currently the output limit is 64 MB.
  • Size Limit Exceeded (SLE) : The source code sent by the user exceeds the size limit. Currently the size limit is 100 KB.
  • Memory Limit Exceeded (MLE) : The program sent by the user tried to use more memory than allowed.
  • Wrong Answer (WA) : The WA judgment means that the program sent by the user finished within the time limit, but the output produced was incorrect. It is important to check the output specification of the problem to avoid this judgment due to, for example, simple white-space errors.
  • Presentation Error (PE) : The output format of the program sent by the user isn't exactly the same as the judge's output, although the answer to the problem is correct. Check the program's output against the output specification of the problem to detect blank lines, spaces, and others.
  • Unqualified (UQD) : The UQD verdict means that the program sent by the user couldn't be run in that moment (engine stopped, datasets no available, among other reasons).
  • Compilation Error (CE) : The CE judgment means that the source code sent by the user couldn't be compiled. Extra information (which can help you to debug the error) can be found on the judgments page. Any compilation time over one minute will cause a CE.
  • Accepted (AC) : The AC judgment means that the program sent by the user has successfully passed all tests and produced the correct output. Congratulations!

CAN I SEE OTHER USERS' SOLUTIONS? 

Yes. This works as follows:

First, you must have an accepted solution to the problem. You cannot see solutions sent to problems that you haven't solved. After you have at least one accepted solution to the problem, you will find a new button in the "Best Solutions" page, labeled "Lock my solutions". When you click that button (and confirm your action), you will be able to see the solutions sent by all the users to that problem. From that moment on, your position on the "best solutions" table will be locked: all subsequent submissions to that problem will be judged by the system, but will not appear on the "best solutions" table. Of course, this action is irreversible: once you have locked your position on the "best solutions" table for a problem, you can never unlock it again. The goal of this action is to further contribute to the learning and training of our users, while maintaining the competitivity of our site at the same time.

ARE THERE SOME CODE SAMPLES? 

The source code sent by the user:

  • should always read the input from the STDIN (Standard Input) and write the output to the STDOUT (Standard Output);
  • should never work with files, threads or other operating system functions;
  • should strictly respect the input and output specifications as indicated in the problem description;
  • should never exceed the limits defined for the problem (execution time, memory usage, size of the source code, and others).
  • Below you can download examples of source code for the problem A+B:

WHAT PROGRAMMING LANGUAGES ARE AVAILABLE? 

Some details about the available programming languages are displayed in the table at the end of this page .

WHICH IS THE MEANING OF INTERNAL ERROR? 

Internal Error is an error in judgments, or engine error, that is supposed which should not happen. Some errors are not internal, because they originate from the source code and they are expected, such as compilation errors or run-time errors; those are commonly reported to users as normal verdicts in the system. But there are errors related with inconsistent or missing datasets, or because the server does not have enough space, or even due errors in system programming; then an unexpected error is originated. That is an Internal Error, and must be closely reviewed by COJ Development Team (CDEVT).

CAN I SEE THE COMPLEXITY OR KNOWLEDGE AREA OF THE PROBLEMS? 

Yes. Almost all problems are associated with one or more tags. A tag is an element which includes both complexity and knowledge area of some problem. If you can´t see the tags in the problems, you should probably go and edit the personal profile and mark the option "Show tags".

The complexity is an estimated integer number which go from 1 to 5: Very Easy (1), Easy (2), Medium (3), Hard (4), Very Hard (5). This is a relative value which is supposed to be established by their authors; but sometimes they are not available at all. Obviously, with the time the users could propose changes to adjust real complexity of some problem.

Although in general is really difficult to make a standard grouping/classification of the knowledge areas related with computing programming, the following proposal used by Caribbean Online Judge to group their problems in categories is pretty close to desired goal:

  • Ad-hoc (AH)
  • Arithmetic-Algebra (AA)
  • Brute Force (BF)
  • Combination (CO)
  • Data Structures (DS)
  • Dynamic Programming (DP)
  • Game Theory (GA)
  • General Geometry (GE)
  • Graph Theory (GT)
  • Greedy (GR)
  • Set-Number Theory (NT)
  • Sorting-Searching (SS)
  • Strings (ST)

Then, problem categorization or tags, could be something like: "GE4" or "NT3, AA3" or "DP3, GT2" (remember that problems can have multiple categorizations but, we certainly avoid to use multiple complexities or unnecessary classifications).

Programming languages Version
Text text file
C# dmcs 3.2.8.0
PHP php5
Prolog SWI Prolog 6.6.4
JavaScript-NodeJS NodeJS v0.10.25
Bash bash 4.3.11
Java openjdk 1.7.0
Pascal fpc 2.6.2
Perl perl 5.18.2
Python python 2.7.6
Ruby ruby 1.9.3
C++ g++ 4.8.4
C gcc 4.8.4
C++11 g++ 4.8.4