Welcome to the Hangman Java Bootcamp Capstone Project! This project is designed to challenge your understanding of Java concepts from Module One. Hangman is a word-guessing game where you'll be building a console-based game that keeps the user guessing until they either correctly guess the word or make too many incorrect guesses.
- Challenge: Hangman is a challenging project that will push your programming skills to the next level.
- Application of Concepts: This project will test your ability to apply concepts learned in Module One of the Java Bootcamp.
- Creativity and Research: Get creative and do some research. As a developer, it's crucial to practice finding resources online.
Ensure that your capstone project contains the following folders:
src
: Source code files.resources
: Resource files, including the list of words and gallows.
If you're missing any folders, download the updated resources from the GitHub Repo.
- Embrace Challenges: Struggling to build Hangman is a positive sign; it means you'll learn a lot by solving it.
- Use Breakpoints: When encountering bugs, use breakpoints to identify and fix issues efficiently.
- Community Support: Don't hesitate to ask questions in the community; it's a great place for support.
As this is your capstone project, instructions are less detailed. They will only provide the task without guiding you toward completing it. Read all instructions before starting your code, and helpful hints are provided at the end.
In the Java Bootcamp Resources -> Module 1 -> Capstone Project
, find Hangman and open it.
Use the provided array of words to choose a random word for the game. Reflect the word's characters with placeholders ('_').
At every turn, display the gallows using the provided array of gallows.
Keep track of and display every incorrect guess made by the user.
When the user guesses correctly, replace the matching placeholders.
Stop the game and display a winning message.
Stop the game and display a losing message.
Enhance the visual appeal of your game by following the specified formatting guidelines.
- Look up how to:
- Convert a String to an array of characters.
- Get the index of a character in a String.
- Loop through characters in a String.
- Check if two arrays are equal to each other.
Consider implementing the following functions:
randomWord()
: Returns a random word from the list of words.checkGuess()
: Returns true if the user guessed a letter from the word correctly.updatePlaceholders()
: Updates placeholders when the user makes a correct guess.printPlaceholders()
: Prints the placeholders.printMissedGuesses()
: Prints guesses that the user missed.
Download the starter project, and let the Hangman challenge begin! Good luck, and enjoy building your Hangman game!
Become a Java Web Developer with our Spring Boot Course (86% Sale)