I just can't seem to comprehend what is happing in the below code I know the theory behind minimax If someone could explain how the moves are scored and finally how the winning move is retrieved in this code,all I understand is when I first make a move the minimax function is called and it stores all avilable moves in a list the there is a while loop which check if the list is exhausted if not it adds a corresponding symbol(X or O) depending on player choice to the board the position at which it is added is given by first number in the stack move_list now it calls minmove func and does the same thing but switches the symbol now maxmove is called this happens as long as the game has not ended if it ends the depends on who won the +INFINITY or -INFINITY is passed to minimax func now after this I am in the dark so someone please help me out my English is not that good I know.its a game of tic tac toe