B modify the hunterville college program so that the

This preview shows page 25 - 32 out of 53 pages.

We have textbook solutions for you!
The document you are viewing contains questions related to this textbook.
Programming Logic and Design, Introductory
The document you are viewing contains questions related to this textbook.
Chapter 5 / Exercise 12
Programming Logic and Design, Introductory
Farrell
Expert Verified
b. Modify the Hunterville College program so that the user enters the rate of tuition increase instead of having it fixed at 4 percent.
We have textbook solutions for you!
The document you are viewing contains questions related to this textbook.
Programming Logic and Design, Introductory
The document you are viewing contains questions related to this textbook.
Chapter 5 / Exercise 12
Programming Logic and Design, Introductory
Farrell
Expert Verified
Programming Logic and Design, 8e
Programming Logic and Design, 8eSolutions 5-27
c. Modify the Hunterville College program so that the user enters the rate of tuition increase for the first year. The rate then increases by 0.5 percent each subsequent year.
Programming Logic and Design, 8eSolutions 5-28Pseudocode:startDeclarationsnum tuitionnum yearnum ratenum TOTAL_YEARS = 10num CURR_TUITION = 15000num PROMPT1 = “Enter the rate of tuition increase for the first year >>”housekeeping()detail()finishUp()stophousekeeping()output PROMPT1input rate
Programming Logic and Design, 8e
12. Yabe Online Auctions requires its sellers to post items for sale for a six-week period during which the price of any unsold item drops 12 percent each week. For example, an item that costs $10.00 during the first week costs 12 percent less, or $8.80, during the second week. During the third week, the same item is 12 percent less than $8.80, or $7.74.Design an application that allows a user to input prices until an appropriate sentinel value is entered. Output is the price of each item during each week, one through six.
Programming Logic and Design, 8eSolutions 5-30Pseudocode:startDeclarationsnum pricenum weeknum TERM = 6num REDUCTION = 0.12string PROMPT = “Enter an item price or 999 to quit >> ”housekeeping()while price <> 999detailLoop()endwhilefinishUp()stophousekeeping()output PROMPTinput pricereturndetailLoop()
Programming Logic and Design, 8e

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture

  • Left Quote Icon

    Student Picture