The aim of competitive programming is to write computer programs which are able to solve given problems. A vast majority of problems appearing in programming contests are mathematical or logical in nature. Typical such tasks belong to one of the following categories:
combinatorics,
number theory,
graph theory,
algorithmic game theory,
computational geometry,
string analysis,
discrete mathematics and
data structures. Problems related to
constraint programming and
artificial intelligence are also popular in certain competitions. Irrespective of the problem category, the process of solving a problem can be divided into two broad steps: constructing an efficient
algorithm, and implementing the algorithm in a suitable
programming language (the set of programming languages allowed varies from contest to contest). These are the two most commonly tested skills in programming competitions. In most contests, the judging is done automatically by host machines, commonly known as judges. Every solution submitted by a contestant is run on the judge against a set of (usually secret) test cases. Normally, contest problems have an all-or-none marking system, meaning that a solution is "Accepted" only if it produces satisfactory results on all test cases run by the judge, and is rejected otherwise. However, some contest problems may allow for partial scoring, depending on the number of test cases passed, the quality of the results, or some other specified criteria. Some other contests only require that the contestant submit the output corresponding to given input data, in which case the judge only has to analyze the submitted output data. Online judges are online environments in which testing takes place. Online judges have rank lists showing users with the biggest number of accepted solutions and/or shortest execution time for a particular problem. == Notable competitions ==