# Kata > EloRating

The Elo rating is used to measuring relative skill of players in zero-sum games like chess.

The probability of player A winning against player B is given by the following formula where R is the rating of each player:

$E_A\ = {1 \over 1 + 10 ^ {(R_A - R_B) / 400}}$

The revised rating of player A after the game is given by:

$R'_A = R_A + K (S_A - E_A)$

S is the actual score and is 1 for win, 0.5 for draw, 0 for loss.

K is a constant. FIDE uses 40 for new players, 20 for players below 2400, and 10 for players above 2400.

Update the rating of a player based on the results of a series of games.