Added BestValue class to improve readability of minimax function
Added next_player function for readability and reduce code duplicate