Advertisement
Coriic

Untitled

Jun 3rd, 2017
119
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. boardFromMinmax board color = addToBoard board (moves!!fromJust(elemIndex (maximum minMaxOfMoves) minMaxOfMoves)) color
  2.     where
  3.         maxLevelOfMinmax = 5
  4.         moves = possibleMoves board
  5.         minMaxOfMoves = Prelude.map (\move -> (minmax (buildTree (addToBoard board move color ) color) color maxLevelOfMinmax)) moves
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement