def human_move(human): # <= here is board removed
legal = legal_moves(board)
where does the board come from here?
If you had it as a parameter then thats where it would come from.
Without a parameter you need to have a global variable called board.
The parameters are the communications context between
your function and the world outside. Everything that your function
needs to operate should be passed into it (or local to it.) At least
thats the ideal.
HTH,
--
Alan Gauld
Author of the Learn to Program web site
http://www.freenetpages.co.uk/hp/alan.gauld
_______________________________________________
Tutor maillist - [email protected]
http://mail.python.org/mailman/listinfo/tutor