Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

(Object Oriented Java Program) War Simulation! Objective: Write a program in which simulates a card game of WAR! The game is simple. There are two

(Object Oriented Java Program)

War Simulation!

Objective:

Write a program in which simulates a card game of WAR! The game is simple. There are two players who each are dealt out 15 cards. Each player lays down a card one at a time. The player with highest value on the card wins both cards back. The player who runs out of cards loses. If they draw the same number, they draw an additional two cards to see who would win. Cards are stored in two stacks per player. One for the cards they are playing with and another for storing the cards they have won.

In this version of the game we will not be using standard playing cards, but instead cards that have unique values ranging from 1-10. This will make the simulation simpler and quicker. The game is played in a "best of" series (The user is asked what they want the best of amount to be, it can be either 3, 5, or 7).

Also remember this program is a simulation of two players playing the game so there is no user input besides whether or not to run another "best of" series again.

Required Methodology

You must use either Java's built in stack implementation or your own stack frame.

Please comment if you have a question.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Design Application Development And Administration

Authors: Mannino Michael

5th Edition

0983332401, 978-0983332404

More Books

Students also viewed these Databases questions

Question

2 What supply is and what affects it.

Answered: 1 week ago