#King of the TournamentTournaments#
In graph theory, a tournamentThis game is a setbased off of N
vertices, where each each vertex is connected to each other vertex with a directed edge. Furthermore, it has been proven that every tournament has at least 1 king.Graph Theory Tournaments
We are going toThe competition will be playing a round-robin tournamentseries of tournaments, where every player plays each player exactly once each round. Then, after the tournament, someKings of the players will be kicked out, and then anothera tournament will start. This cycle will repeatplay in the next until 1 playerthe winner(s) is victorious.found
#The Tournament#
At the beginning of eachEvery player will play every other player exactly once in a tournament, the players. Each player will be randomly ordered fromrecieve 15*N
topoints each tournament (where N
andis the number of opponents in that tournament). Furthermore, each player will receivehave an advantage over N*5N/2
points. (This ordering will be circular...imagine each player sitting in a circleplayers, so theand a disadvantage to N/2
th player players. This advantage is next todecided at the first)
Then, each player will face every other player exactly oncebeginning of the game.
#The Battle#
For eachEach battle, each player will decide how manyconsist of a player commiting X
points to use to fight the other. These Whoever commits more points will be subtracted from their total they received at the beginningwin that battle. If they both usedplayers commit the same amount of points, then the following will beplayer with the tie breakersadvantage over the other will win.
- The player with the least points
- If the space between P1 to P2 is smaller than the space between P2 to P1, then P1 will win (If there are 5 players, the distance between P1 to P4 is 3, while P4 to P1 is 2)
- The player who won last between the two
- Multiply the round number by 2 (there are N/2 rounds). The player whose turn number most immediately follows the round number will win
#End ofAfter a tournament, the tournament#
The kings ofKings will be the tournament are determined as followed:
A King must haveplayers that defeateddefeat everyall other playerplayers. P1
has defeateddefeats P2
if P1
directly beat P2
in battle, or if P1
beat a P3
in battle whoplayer that beat P2
in battle.
If a tournament ends, and every player is a king If all players are kings, then the players with the least amountamounts of wins in the most recentthis tournament will be removedare eliminated. If all players have the same amount of wins, then the players with the least amount of total amount of wins will be removedare eliminated. If this is In the same as wellcase of a tie, then everythe remaining player will beplayers are declared victorious.the winners
#IO#
Your bot must stay alive throughout the entire game. You will pass in a number every round through STDOUT. You may pass in a few codes through STDOUT to recieve information via STDIN:
YouW
will return IDs of the players you have 3 choices aswon to howthis tournament
L
will return the IDs of the players you have lost to do your IO:this tournament
##Stay alive##
Your programOW
will continuously run throughoutreturn the entireIDs of the players your opponent has won this tournament. No output
OL
will be passed toreturn the IDs of the players your program unless explicitly requested. Each battle,opponent has lost to this tournament
A
will return 1 if you have an advantage over the player, else 0
H
will outputreturn the numberhistory of your battles against the player. The list will be comma-seperated, where each battle is represented by Num1/Num2
where Num1 is the points you want to usecommitted, and input any data you requestNum2 is the points your opponent committed.
"R" will return the round number
"O" will return the total number of opponents
"P" will return the number of points you have
"I" will return the player's ID (his initial position)
"C" will return two comma separated numbers of your win and loss count
"D" will return two comma seperated numbers of your opponent's win and loss count
"W" will return a comma-separated list of players' IDs you have won (this round)
"L" will return a comma-separated list of players' IDs you have lost (this round)
"V" will return a comma-separated list of players' IDs that the player has won
"M" will return a comma-separated list of players' IDs that the player has lost