Chapter 2 Programming Problem

Chapter 2 Programming Problem - Each of the following...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
Each of the following problems can be solved by a program that performs three basic tasks —Input Data, Process Data, and Output Results. For each problem, use pseudocode to design a suitable program for solving it. 1.  Input a saleswoman’s sales for the month (in dollars) and her commission rate (as a percentage), and output her commission for that month. Input Data  Input Sales for Month, CommissionRate Process Data Compute Sales for Month Compute CommissionRate Compute TotalCommission Output Results  Output the input data and TotalCommission 2.  The manager of the Super Supermarket would like to be able to compute the unit price for products sold there. To do this, the program should input the name and price of an item and its weight in pounds and ounces. It should then determine and display the unit price (the price per ounce) of the item. Input Data Input ItemName, UnitPrice, UnitWeight Process Data Compute UnitPrice Compute UnitWeight Output Results Output the input data and TotalPrice
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 3

Chapter 2 Programming Problem - Each of the following...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online