Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Objective: Become more familiar with C++ I/O and basic conditional operations. Description: Write a program to play Rock, Paper, Scissors, Lizard Spock. A user will

image text in transcribed

Objective: Become more familiar with C++ I/O and basic conditional operations. Description: Write a program to play "Rock, Paper, Scissors, Lizard Spock." A user will enter a character to represent one of the five items The program will randomly select one of the five items. Once these two objects have been determined, the program will decide who wins: . Rock beats Scissors Paper beats Rock Scissors beats Paper See http://www.samkass.com/theories/RPSSL.html for additional rules. Outline of solution 1. Display your standard output information using a function named ShowProgramHeader() as on the previous assignments 2. Prompt user for input (rock, paper, scissors, lizard, or Spock) 3. Get input from user (first player) - using a function. 4. Generate second player's object (get input from user for second player for initial testing)-using a function. 5. Decide and display outcome of the game - using a function Deliverables: Program-fully documented. Your final program should contain all test code used during development. . Output test your program using the following input data: R P, p Hint: do this before implementing the computer as player 2 P, p P, L K. Output-at least five games using the computer as player 2

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

Main Memory Database Systems

Authors: Frans Faerber, Alfons Kemper, Per-Åke Alfons

1st Edition

1680833243, 978-1680833249

More Books

Students also viewed these Databases questions

Question

3-1 Define hedonic consumption and provide an example.

Answered: 1 week ago

Question

Define span of management or define span of control ?

Answered: 1 week ago

Question

What is meant by formal organisation ?

Answered: 1 week ago

Question

What is meant by staff authority ?

Answered: 1 week ago

Question

Discuss the various types of policies ?

Answered: 1 week ago