In: Computer Science
Must be done in Visual Studios
A retail company must file a monthly sales tax report listing the sales for the month and the amount of sales tax collected. Write a program that asks for the month, the year, and the total amount collected at the cash register (that is, sales plus sales tax). Assume the state sales tax is 4 percent and the county sales tax is 2 percent.
If the total amount collected is known and the total sales tax is 6 percent, the amount of product sales may be calculated as:
S = T/1.06
S is the product sales and T is the total income (product sales plus sales tax).
The program should display a report similar to the following. Be sure and read the section of setprecision(),setw() and use these formatting options for the output.
Month: October
----------------------------
Total Collected: $ 26572.89
Sales: $ 25068.76
County Sales Tax: $ 501.38
State Sales Tax: $...1002.75
Total Sales Tax $ 1504.13
#include
#include
using namespace std;
int main()
{
string month;
double totalPrice, countrySaleTax,stateSaleTax;
cout<<"Enter the month: ";
cin >> month;
cout<<"Enter Total Collected: ";
cin >> totalPrice;
double sales = totalPrice/1.06;
countrySaleTax = (sales * 2)/100;
stateSaleTax = (sales * 4)/100;
double totALSalesTax = stateSaleTax + countrySaleTax;
cout<<"Month: "<
return 0;
}
Output: