finished minimax, removed while loop from greedy

Also commented and stylized minimax