Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Do not remove the questions or text from the Template. Mark any additions to the pseudocode by adding lines and showing them in red. Strikeout

Do not remove the questions or text from the Template. Mark any additions to the pseudocode by adding lines and showing them in red. Strikeout any deletions using the strikeout tool. Assume that the pseudocode below for each question is a separate working program in your organization and that it needs modifications as described in the comments (lines that begin with two slashes) at the beginning of the code. Your job is to alter the pseudocode to meet the new specifications as noted above. Please follow directions as specified in the homework assignment instructions file.NOTE: If a function has no changes to be made to it, then it will be in blue font.
// The FastCopy company currently makes 100,000 copies per year at 15
// cents each. They expect to increase the number of copies produced
// by 4 percent per year each year for the next 10 years, starting with
// this year. They also expect the price of each copy to increase by 3
// cents per year, starting with this year. This program displays the
// company's expected income for each of the next 10 years.Modify it to
// be more efficient by using a while loop and correct any mistakes with
// variable values, etc. You may have to add a new variable as well. You
// may go ahead and remove repeated code.
start
// Declarations
num year =1
num copies =100,000
num price =15
num total
num COPIES_INCREASE =4
num PRICE_INCREASE =3
num YEARS
copies = copies + copies * COPIES_INCREASE
price = price + price * PRICE_INCREASE
total = total + copies * price
output year, total
year = year +1
copies = copies + copies * COPIES_INCREASE
price = price + price * PRICE_INCREASE
total = total + copies * price
output year, total
year = year +1
copies = copies + copies * COPIES_INCREASE
price = price + price * PRICE_INCREASE
total = total + copies * price
output year, total
year = year +1
copies = copies + copies * COPIES_INCREASE
price = price + price * PRICE_INCREASE
total = total + copies * price
output year, total
year = year +1
copies = copies + copies * COPIES_INCREASE
price = price + price * PRICE_INCREASE
total = total + copies * price
output year, total
year = year +1
copies = copies + copies * COPIES_INCREASE
price = price + price * PRICE_INCREASE
total = total + copies * price
output year, total
year = year +1
copies = copies + copies * COPIES_INCREASE
price = price + price * PRICE_INCREASE
total = total + copies * price
output year, total
year = year +1
copies = copies + copies * COPIES_INCREASE
price = price + price * PRICE_INCREASE
total = total + copies * price
output year, total
year = year +1
copies = copies + copies * COPIES_INCREASE
price = price + price * PRICE_INCREASE
total = total + copies * price
output year, total
year = year +1
copies = copies + copies * COPIES_INCREASE
price = price + price * PRICE_INCREASE
total = total + copies * price
output year, total
stop

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

Practical Neo4j

Authors: Gregory Jordan

1st Edition

1484200225, 9781484200223

More Books

Students also viewed these Databases questions

Question

=+6. What five driving forces make CSR more relevant today?

Answered: 1 week ago