//flex table opened by JP

Click to See Complete Forum and Search --> : Tic-tac-toe


nothing
05-05-2005, 04:30 PM
Hi. I wrote a tic-tac-toe for the console in C++ and it's pretty nice. The only problem is that it lacks intelligence and I was wondering if anyone could help me make my game unbeatable. Everything is done, I just need help with this part. Does anyone have any ideas to share with me? I tried looking at some source code but it was javascript and I didn't understand it. Thanks a lot.

Baddog
05-05-2005, 04:32 PM
The only way to be unbeatable is for the program to make the first move.:cool:

kpm547
05-05-2005, 05:50 PM
tic-tac-toe is not totally random. The person who makes the first move is able to win every time.