run p str b le = do putStrLn $ "Turn to Player " ++ show p
                    edge <- fst str b le
                    putStrLn $ "Player " ++ show p ++ " moves to " ++ show edge
                    nb <- updateBoard b edge p
                    if snd nb then do putStrLn "SQUARE!!!"
                                      run p str (fst nb) (deleteAvailable edge le )
                    else run (changePlayer p) (changeStrategy str) (fst nb) (deleteAvailable edge le)
run p str b le = do putStrLn $ "Turn to Player " ++ show p
                    edge <- fst str b le
                    putStrLn $ "Player " ++ show p ++ " moves to " ++ show edge
                    nb <- updateBoard b edge p
                    if snd nb then do putStrLn "SQUARE!!!"
                                      run p str (fst nb) (deleteAvailable edge le )
                    else run (changePlayer p) (changeStrategy str) (fst nb) (deleteAvailable edge le)
run p str b le = do putStrLn $ "Turn to Player " ++ show p
                    edge <- fst str b le
                    putStrLn $ "Player " ++ show p ++ " moves to " ++ show edge
                    nb <- updateBoard b edge p
                    if snd nb then do putStrLn "SQUARE!!!"
                                      run p str (fst nb) (deleteAvailable edge le )
                    else run (changePlayer p) (changeStrategy str) (fst nb) (deleteAvailable edge le)