Project

Tic-Tac-Toe with AI (Java)

Hard
1706 completions
~ 23 hours
4.5

After finishing this project, you'll get to know a lot about planning and developing a complex program from scratch, using classes and methods, handling errors, and processing user input. You will also learn to use OOP (Object-Oriented Programming) in the process.

Provided by

JetBrains Academy JetBrains Academy

About

Everybody remembers this paper-and-pencil game from childhood: Tic-Tac-Toe, also known as Noughts and crosses or Xs and Os. A single mistake usually costs you the game, but thankfully it is simple enough that most players discover the best strategy quickly. Let’s program Tic-Tac-Toe and get playing!

Training project icon

Training project

This project allows you to practice and strengthen your coding skills, helping you get ready for more advanced tasks ahead.

What you'll learn

Once you choose a project, we'll provide you with a study plan that includes all the necessary topics from your course to get it built. Here’s what awaits you:
Create an easy difficulty level where the computer just makes random moves: simple to write and not too challenging to beat.
Choose whether you want to play with a friend or take a break and watch computers battle it out!
It's time to add a medium difficulty level. This AI should be a lot harder to beat! Are you up to the challenge?
Oh no, what have we created here? An unbeatable AI monster! Indeed, this complex algorithm guarantees a win or a draw.

Reviews

User 146657103
4 months ago
I have learned about recursion and make classes have only one responsibility.
Rafal Caban
5 months ago
Most of the project was easy for me except the algorithm minmax I struggled to understand and implement.
Polamarasetti Neeraj Babu avatar
Polamarasetti Neeraj Babu
6 months ago
It is mainly useful to learn all the basic of java and implement on the project.

4.5

Learners who completed this project within the Java Desktop Application Developer course rated it as follows:
Usefulness
4.6
Fun
4.5
Clarity
4.4