Ai for 'Bulls and cows' game. (mastermind)