Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Resolve with C + + Redo Programming Exercise 1 6 of Chapter 4 so that all the named constants are defined in a namespace royaltyRates.

Resolve with C++
Redo Programming Exercise 16 of Chapter 4 so that all the named constants are defined in a namespace royaltyRates.
Instructions for Programming Exercise 16 of Chapter 4 have been posted below for your convenience.
Exercise 16
A new author is in the process of negotiating a contract for a new romance novel. The publisher is offering three
options. In the first option, the author is paid $5,000 upon delivery of the final manuscript and $20,000 when the novel
is published. In the second option, the author is paid 12.5% of the net price of the novel for each copy of the novel
sold. In the third option, the author is paid 10% of the net price for the first 4,000 copies sold, and 14% of the net price
for the copies sold over 4,000. The author has some idea about the number of copies that will be sold and would like
to have an estimate of the royalties generated under each option. Write a program that prompts the author to enter
the net price of each copy of the novel and the estimated number of copies that will be sold. The program then
outputs the royalties under each option and the best option the author could choose. (Use appropriate named
constants to store the special values such as royalty rates and fixed royalties.)
image text in transcribed

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 Systems A Practical Approach To Design Implementation And Management

Authors: THOMAS CONNOLLY

6th Edition

9353438918, 978-9353438913

Students also viewed these Databases questions