Question

Archie wants a program that calculates and displays a team’s final score in a football game,...

Archie wants a program that calculates and displays a team’s final score in a football game, given the numbers of the team’s field goals, touchdowns, one-point conversions, two-point conversions, and safeties. First, create an IPO chart for this problem, and then desk-check the algorithm twice. For the first desk-check, use 3, 2, 2, 0, and 1 as the numbers of field goals, touchdowns, one-point conversions, two-point conversions, and safeties. For the second desk-check, use your own set of data. After desk-checking the algorithm, list the input, processing, and output items in a chart similar to the one shown in Figure 3-25, and then enter the appropriate C++ declaration statements

Fig 3.25

IPO chart information C++ instructions

Input latexprice

Mylar price

latex purchased

Mylar purchased

sales tax rate (6%)

Processing

total latex cost total Mylar costs

sub total sales tax

Output

total cost

Homework Answers

Answer #1

IPO CHART INFORMATION

INPUT:

    field goals

   touch downs

   one point conversation

   two point conversation

   safeties

PROCESSING:

     total team score

OUTPUT:

display total score

C++ INSTRUCTIONS:

OUTPUT: double totalScore=0.0;

PROCESSING:       double totalteamScore=0.0;

INPUT:     double fieldGoals=0.0;

               double one-point convo=0.0;

              double two-point convo=0.0;

               double touchdown=0.0;

             int safeties;

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
A local department store is having a BOGOHO (Buy One, Get One Half Off) sale. The...
A local department store is having a BOGOHO (Buy One, Get One Half Off) sale. The manager wants a program that allows salesclerks to enter the prices of two items. The program should calculate and display the total amount the customer owes. The half-off should always be taken on the item having the lowest price. If the items cost $24.99 and $10, the half-off would be taken off the $10 item. If both prices are equal, take the half-off on...
You have decided to volunteer at your local history museum which sells tickets for admission. The...
You have decided to volunteer at your local history museum which sells tickets for admission. The museum curator has asked you to write a program that can help calculate the cost of one ticket for admission to the museum. Children under 6 are admitted for free, while all other children are charged $2.93 per ticket. Adults (18 and over) are charged $8.65 per ticket. All tickets that are not free have a convenience cost of $0.85, and all sales are...
Sign In INNOVATION Deep Change: How Operational Innovation Can Transform Your Company by Michael Hammer From...
Sign In INNOVATION Deep Change: How Operational Innovation Can Transform Your Company by Michael Hammer From the April 2004 Issue Save Share 8.95 In 1991, Progressive Insurance, an automobile insurer based in Mayfield Village, Ohio, had approximately $1.3 billion in sales. By 2002, that figure had grown to $9.5 billion. What fashionable strategies did Progressive employ to achieve sevenfold growth in just over a decade? Was it positioned in a high-growth industry? Hardly. Auto insurance is a mature, 100-year-old industry...