Advertisement
Guest User

Untitled

a guest
Jul 21st, 2017
54
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.80 KB | None | 0 0
  1. // AssignmentPg.78.cpp : Defines the entry point for the console application.
  2. //
  3.  
  4. #include "stdafx.h"
  5. #include <iostream>
  6. using namespace std;
  7.  
  8. int _tmain(int argc, _TCHAR* argv[])
  9. {
  10.     Float Item1, Item2, Item3, Item4, Item5, Subtotal, SalesTax, Total;
  11.     Item1 = 12.95;
  12.     Item2 = 24.95;
  13.     Item3 = 6.95;
  14.     Item4 = 14.95;
  15.     Item5 = 3.95;
  16.     Subtotal = Item1 + Item2 + Item3 + Item4 + Item5;
  17.     SalesTax = Subtotal * 0.06;
  18.     Total = Subtotal + SalesTax;
  19.    
  20.     cout << "Item 1 = $" << Item1 << endl;
  21.     cout << "Item 2 = $" << Item2 << endl;
  22.     cout << "Item 3 = $" << Item3 << endl;
  23.     cout << "Item 4 = $" << Item4 << endl;
  24.     cout << "Item 5 = $" << Item5 << endl;
  25.  
  26.     cout << "Subtotal = $" << Subtotal << endl;
  27.     cout << "SalesTax = $" << SalesTax << endl;
  28.     cout << "Total = $" << Total << endl;
  29.  
  30.     return 0;
  31. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement