View the step-by-step solution to:

Develop a program that follows the rules of Liar's Dice as described. On program start-up, it shall display the rules to the user as read from a text...

Develop a program that follows the rules of Liar's Dice as described. On program start-up, it shall display the rules to the user as read from a text file submitted with the program. The user can then set up the game by entering the number of players. Any number below two shall ask the user to add more players. Once gameplay has started based on the game rules, there are a few main pieces to address. Rolling the die should be performed by randomly generating the side of the die displayed for all of the dice (five per player) using a random number generator. This rolling only happens once at the beginning of the game. On each player's turn, the player should be able to view his/her dice only and enter their guess into the system. Continue playing until a player decides to call liar. Then show the full set of dice and determine if the last entered guess was correct. Display a message to the game winner (the player who made the guess if it was correct, the player that called liar if the guess was not correct). 


I know how to get documents/text files to display. Im not quite sure the best bay to split this into classes though and have been having difficulty creating a code to function for this game successfully. Thank you in advance for your assistance!

Recently Asked Questions

Why Join Course Hero?

Course Hero has all the homework and study help you need to succeed! We’ve got course-specific notes, study guides, and practice tests along with expert tutors.

-

Educational Resources
  • -

    Study Documents

    Find the best study resources around, tagged to your specific courses. Share your own to gain free Course Hero access.

    Browse Documents
  • -

    Question & Answers

    Get one-on-one homework help from our expert tutors—available online 24/7. Ask your own questions or browse existing Q&A threads. Satisfaction guaranteed!

    Ask a Question