Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Using C++ program Part 1: (50 points) You are creating a program for a raffle. The each ticket for the raffle costs 5 dollars to

Using C++ program image text in transcribed
Part 1: (50 points) You are creating a program for a raffle. The each ticket for the raffle costs 5 dollars to enter, and contestants may purchase a ticket as many times as they like. When entries for the raffle are closed, one winning ticket is selected at random. The winner gets 75% of the entry fees a prize, and the company running the raffle keeps the remaining 25%. Your solution should have the following requirements: The program will prompt the user to enter a new name for each ticket sold The program will prompt the user to enter "Q" to finish selling tickets The program will randomly select a winner The program will display the total number of participants, the name of the winner, and the prize money won Assume each name is unique and keep names one word (no spaces), Before moving on to part 2, ensure you have part 1 working and completed. Part 2: (20 points- 10 bonus points) Extend the raffle program by adding the ability to view statistics about the entries. Display the names of each entry and the percent chance of them winning the raffle before determining the winner. Assuming no two people have the same name, determine how many tickets were purchased by each person, and divide that number by the total number of tickets to determine the percent chance of winning

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_2

Step: 3

blur-text-image_3

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 Technology And Management Computers And Information Processing Systems For Business

Authors: Robert C. Goldstein

1st Edition

0471887374, 978-0471887379

More Books

Students also viewed these Databases questions

Question

KEY QUESTION Refer to Figure 3.6, page

Answered: 1 week ago