Recent Feedback
using the for statement c++ need help
Optional Information: Language (or Software): C++ Already Tried: everything
hi
Welcome
im doing the for statement
How can I help]
one sec let me upload the assignment
ok
Purpose: Provide ACME.COM an interactive program that helps the sales department to determine the pricing of products sold to customers. The only data provided by the user is customer name, product name, and product price. Sale Tax will be based upon a 7% sale tax rate provided for the user. The program's main function will be to calculate the cost of from 1 to 15 of these products the tax on the sale, and total amount due. VARIABLE DICTIONARY VARIABLES TYPE REPRESENT name_of_product String Product Name price_of_product Double Price of product reply String Yes or No to run program again price_quotation_max Int Price Quotation will not exceed 15 total_price Double Total Price sales_tax Int Sales Tax company_name String Customers Name number_of_items Int Number of Items */ #include
Purpose: Provide ACME.COM an interactive program that helps the sales department to determine the pricing of products sold to customers.
The only data provided by the user is customer name, product name, and product price. Sale Tax will be based upon a 7% sale tax rate provided for the user. The program's main function will be to calculate
the cost of from 1 to 15 of these products the tax on the sale, and total amount due.
VARIABLE DICTIONARY
VARIABLES TYPE REPRESENT
name_of_product String Product Name
price_of_product Double Price of product
reply String Yes or No to run program again
price_quotation_max Int Price Quotation will not exceed 15
total_price Double Total Price
sales_tax Int Sales Tax
company_name String Customers Name
number_of_items Int Number of Items
*/
#include
<iostream>
<string>
<iomanip>
using
std;
int
i, x, price_quotation_max, number_of_items, total_tax; string company_name, reply, name_of_product;
string company_name, reply, name_of_product;
double
a, b, c, d, total_price, price_of_product, cost_of_items, sales_tax, total_taxes;
void
setup();
heading();
input();
calculations ();
main () { setup(); heading(); input(); calculations();
{
calculations();
/*cout.setf(ios::fixed, ios::floatfield); cout.setf(ios::showpoint); cout.precision(3); a = 3.4; b = XXX.XXXX; c = 0.12; d = 1.9876;*/
cout.setf(ios::showpoint);
cout.precision(3);
a = 3.4;
b = XXX.XXXX;
c = 0.12;
d = 1.9876;*/
/*cout<< setw(6) << a << endl; cout<< setw(6) << b << endl; cout<< setw(6) << c << endl; cout<< setw(6) << d << endl;*/
cout<< setw(6) << b << endl;
cout<< setw(6) << c << endl;
cout<< setw(6) << d << endl;*/
/*for(i = 1; i <= 20; i++) { cout.width(6); cout << i << endl; }*/
cout.width(6);
cout << i << endl;
}*/
cout<<
<<endl; cout<<
; cin >> reply;
cin >> reply;
) { input (); heading(); calculations (); cout<<
input ();
; cin>>reply; }
cin>>reply;
}
//end loop
0; system (
system (
); }
//Setup Start
setup () { sales_tax = 7; price_quotation_max = 15 ; }
sales_tax = 7;
price_quotation_max = 15 ;
//Setup End
//Heading Start
heading () { cout<<
; cin >> reply; cout<<
<<endl; }
//Heading End
//Input Start
input () { cout<<
;cin>>company_name; cout<<
;cin>>name_of_product; cout<<
;cin>>price_of_product; cout<<
//End Input
//Calculations/Output
calculations () {
(x = 1; x <= price_quotation_max; x = x + 1) { number_of_items = x + 0; cost_of_items = price_of_product * x ; total_taxes = cost_of_items * sales_tax ; cout<<number_of_items<< cost_of_items<< total_taxes<< total_price<<endl;
number_of_items = x + 0;
cost_of_items = price_of_product * x ;
total_taxes = cost_of_items * sales_tax ;
cout<<number_of_items<< cost_of_items<< total_taxes<< total_price<<endl;
; } }
Can you please send me the files you have been working with ?Can you please go to www.wikisend.com and upload your file ? Once you do that you will get a page that has the "File ID" and "Download Link". Copy the "Download Link" or "File ID" and please paste it in your reply here.
http://wikisend.com/download/517268/assign6.cpp
were are just learning how to use the for statement
going through it
all we have been taught is the while and for loop
how soon do you need this ?
by tonight
9:23 est here
so in 2 hrs from now ?
2 hours you said
do i just stay in chat with you
hang on
let me see if I can do it this soon
im here if you need anything from me
yep, still working on it
k np
k
you still here it said you left chat lol
yes I am here
dont worry
k cool
let me sned what I have
Download assign6.cpp
let me know if it looks ok
all the numbers are going to the left
are you running the file I gave you ?
yup
it is runing just fine here
I can send a screenshot
one sec
Screenshot Download
k all set
cool
Please click the Green accept button if you think my answer helped, so that I get credited for the time spent. I would obviously continue to help you if you have any further questions.
Please start your question text with "For ATLProg Only" to request me again, next time you need help! http://www.justanswer.com/computer/expert-atlprog/ - Please bookmark this link to ask new question.
ty
ywc
Experience: MS in IT.Several years of programming experience in Java C++ C C# Python VB Javascript HTML