Algorithm::Elo
use Algorithm::Elo;
my ( $player-a-score, $player-b-score ) = 1_600, 1_600;
( $player-a-score, $player-b-score ) = calculate-elo($player-a-score, $player-b-score, :left);
This module implements the Elo rating system, commonly used to rate chess players.
Given two current ratings and the result of a match (:left
if the left player wins, :right
if the right player wins, :draw
for a draw), return two new ratings for the left and right players.
-
Rob Hoelz
-
Raku Community
Copyright (c) 2015 - 2017 Rob Hoelz
Copyright (c) 2024 Raku Community
This library is free software; you can redistribute it and/or modify it under the MIT license.