Rock-paper-scissors: Difference between revisions

m
added whitespace before the TOC (table of contents), added a ;Task: (bold) header, changed AI to bold, otherwise it looked like Al (Alfred). .
m (→‎{{header|REXX}}: changed/added comments and whitespace, changed indentations.)
m (added whitespace before the TOC (table of contents), added a ;Task: (bold) header, changed AI to bold, otherwise it looked like Al (Alfred). .)
Line 1:
{{task|Games}}
{{task|Games}}The task is to implement the classic children's game [[wp:Rock-paper-scissors|Rock-paper-scissors]], as well as a simple predictive AI player.
 
;Task:
Rock Paper Scissors is a two player game. Each player chooses one of rock, paper or scissors, without knowing the other player's choice. The winner is decided by a set of rules:
{{task|Games}}The task is to implementImplement the classic children's game [[wp:Rock-paper-scissors|Rock-paper-scissors]], as well as a simple predictive &nbsp; '''AI''' &nbsp; (<u>a</u>rtificial <u>i</u>ntelligence) &nbsp; player.
 
Rock Paper Scissors is a two player game.
* Rock beats scissors
* Scissors beat paper
* Paper beats rock.
 
Rock Paper Scissors is a two player game. Each player chooses one of rock, paper or scissors, without knowing the other player's choice. The winner is decided by a set of rules:
 
The winner is decided by a set of rules:
 
:::* &nbsp; Rock beats scissors
:::* &nbsp; Scissors beat paper
:::* &nbsp; Paper beats rock.
 
<br>
If both players choose the same thing, there is no winner for that round.
 
For this task, the computer will be one of the players.
For this task, the computer will be one of the players. The operator will select Rock, Paper or Scissors and the computer will keep a record of the choice frequency, and use that information to make a [[Probabilistic choice|weighted random choice]] in an attempt to defeat its opponent.
 
For this task, the computer will be one of the players. The operator will select Rock, Paper or Scissors and the computer will keep a record of the choice frequency, and use that information to make a [[Probabilistic choice|weighted random choice]] in an attempt to defeat its opponent.
 
 
;Extra credit:
'''ExtraSupport credit:'''additional easychoices support for&nbsp; [[wp:Rock-paper-scissors#Additional_weapons|additional weapons]].
<br><br>
 
=={{header|Ada}}==