Class: Tictactoe::DumbPlayer
- Defined in:
- lib/tictactoe/dumbplayer.rb
Instance Attribute Summary
Attributes inherited from Player
Instance Method Summary collapse
Methods inherited from Player
Constructor Details
This class inherits a constructor from Tictactoe::Player
Instance Method Details
#move(board) ⇒ Object
7 8 9 10 |
# File 'lib/tictactoe/dumbplayer.rb', line 7 def move( board ) moves = board.moves moves[rand(moves.size)] end |