Question

A store sells cups and plates for parties. The owners want a program that allows them...

A store sells cups and plates for parties. The owners want a program that allows them to enter the price of a cup, the price of a plate, the number of cups purchased, the number of plates purchased, and the sales tax rate. The program should calculate and display the total cost of the purchase.

desk check the pseudocode

0 0
Add a comment Improve this question Transcribed image text
Answer #1

C++ :

OUTPUT :

CODE :

#include <iostream>

using namespace std;

int main()

{

//Declare variables to store user input

int cups,plates; //to store number of cups and plates

double cost_cups, cost_plates; //to store price of cups and plates

double tax_rate; //to store sales tax rate;

double sell_price,tax_amount, net_amount;

//to store selling price tax amount and sell_price after adding tax

//Ask user for data

cout << "Enter number of cups : ";   cin>>cups;

cout << "Enter number of plates : ";   cin>>plates;

cout << "Enter price per cups : ";   cin>>cost_cups;

cout << "Enter price per plates : ";   cin>>cost_plates;

cout<<"Enter sales tax rate in % : "; cin>>tax_rate;

//Calculate sell_price and tax

sell_price = cups * cost_cups + plates * cost_plates;

tax_amount = sell_price * tax_rate/100.0;

net_amount = sell_price + tax_amount;

//Display final data

cout<<" Total cost = "<<net_amount<<" ";

}

Add a comment
Know the answer?
Add Answer to:
A store sells cups and plates for parties. The owners want a program that allows them...
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. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • A store is having a sale. The manager wants a program that allows the sales clerk...

    A store is having a sale. The manager wants a program that allows the sales clerk to enter the original price of an item and the discount rate. The program should calculate and display the sale price. find the inputs and outputs, write the pseudocode, and desk check the pseudocode.

  • Mountain Coffee wants a program that allows a clerk to enter the number of pounds of...

    Mountain Coffee wants a program that allows a clerk to enter the number of pounds of coffee ordered, the price per pound, and whether the customer should be charged a 3.5% sales tax. The program should calculate and display the total amount the customer owes. Use an int variable for the number of pounds, a double variable for the price per pound, and a char variable for the sales tax information. a. Create an IPO chart for the problem, and...

  • NOTE:- NO "BREAK" COMMAND PLEASE This program allows the user to create a grocery list, which...

    NOTE:- NO "BREAK" COMMAND PLEASE This program allows the user to create a grocery list, which will give them a breakdown of each item they want to buy, including the amount that should be purchased. The program must use two separate lists to accomplish this! The user can continue entering items indefinitely, stopping only when theyenter the sentinel value “END”. After entering each item, they should be asked how many of that item they want to buy. After their list...

  • Project Description Complete the Film Database program described below. This program allows users to store a...

    Project Description Complete the Film Database program described below. This program allows users to store a list of their favorite films. To build this program, you will need to create two classes which are used in the program’s main function. The “Film” class will store information about a single movie or TV series. The “FilmCollection” class will store a set of films, and includes functions which allow the user to add films to the list and view its contents. IMPORTANT:...

  • How do you write out this C++ program and zip the files? A local department store...

    How do you write out this C++ program and zip the files? A local department store is having a BoGoHo (Buy One, Get One Half Off) sale. The store manager wants a program that allows the salesclerk 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. For example, if the items cost $24.99 and $10, the half-off...

  • 25. In this exercise, you create a program for the sales manager at Computer Haven, a...

    25. In this exercise, you create a program for the sales manager at Computer Haven, a small business that offers motivational seminars to local companies. Figure 7-53 shows the charge for attending a seminar. Notice that the charge per person depends on the number of people the company registers. For example, the cost for four registrants is $400; the cost for two registrants is $300. The program should allow the sales manager to enter the number of registrants for as...

  • Computer science help! A software company sells their software packages for $99.00 each. They would like...

    Computer science help! A software company sells their software packages for $99.00 each. They would like you to write a program that will calculate and display an invoice for their customers. Quantity discounts are given according to the following table: Quantity   Discount 1 - 9 No discount 10 – 19 20% 20 – 49 30% 50 - 99 40% 100 or more 50% Write a C++ program that asks for the customer’s name and the number of software packages sold...

  • Answer using C++ Write a program that will calculate the final sales price of a motorcycle;...

    Answer using C++ Write a program that will calculate the final sales price of a motorcycle; this includes additional optional packages along with sales tax. You may assume that the base? price of the motorcycle is $30,000. First you must ask the user to choose which optional packages they want. The user is only permitted to choose one package. Your program should display a menu of the available packages. The user should enter the package by entering the letter associated...

  • I need help building code in python for this: Create a program that: Creates a sales...

    I need help building code in python for this: Create a program that: Creates a sales receipt, displays the receipt entries and totals, and saves the receipt entries to a file Prompt the user to enter the Item Name Item Quantity Item Price Display the item name, the quantity, and item price, and the extended price (Item Quantity multiplied by Item Price) after the entry is made Save the item name, quantity, item price, and extended price to a file...

  • java; programing language Write a program to calculate the price of a purchase. It should ask...

    java; programing language Write a program to calculate the price of a purchase. It should ask the user to enter the name of the item bought (like sweater, apple, …), number of items bought (4, 5 lbs,…), price per item ($40.50, $1.99 per pound,…), and the sales tax rate (8.35% for example). It should calculate the subtotal (price*number of items), sales tax (subtotal*sales tax), and total price (subtotal+ sales tax). It should print all the information in a receipt form

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT