Advertisement

Kinda new.

Started by November 06, 2000 09:24 PM
0 comments, last by tftd 24 years, 1 month ago
After a while of studying different programming languages, I decided to get my hands dirty by diving in and writing my own program. So I picked my favorite compiler (the free one of course) and started programming. After many faied attempts to write a program that would take over the world for me, I decided to make something simplier and made a tic tac toe game. Well I got it to work pretty decently (yeah right) but I hit a road block in programming the ai aspect of the game(being the great genius I am). So I was wondering if I could get some advice from you all wise and all knowing (do I really have to beg?) programmers. I managed to make the ai pick the winning move when it occurs. But know I''m wondering how I could make the ai more advanced. I want it to more agressive on the user, and for it to provide a more of a challenge. I was thinking of taking the brute force approach by programming in all the different types of strategies, but I was wondering if there was something better I could do( as well as easier). Thanks for the help and I hope you didn''t take my ideas for world domination to seriously ( haha suckers, they''ll never see me coming ... wait a sec, you''re not supposed to see this part ... DOH!)
C:WindowsSystemReality.sys crashed!Reboot Universe? [Y/N]
Well, first off, I''m not sure how you are programming AI for your tic tac toe game, but if you used the right method (tree searching), then your tic tac toe game would never lose, since the entire tree for the game of tic tac toe is 9! = 362880 possible positions. A decent searching algorithm would take a few seconds to search this, maybe more depending on how fast your computer is. If you want to learn more about what I''m talking about read the Chess Programming article in gaemdev.net''s Article section. It discusses how to make a chess program, but you could easily create a tic tac toe game from the info there.

Russell

This topic is closed to new replies.

Advertisement