66 896
Assignments Done
99,1%
Successfully Done
In October 2018

Answer to Question #8815 in C++ for alex lee

Question #8815
Write a function calculateItemCost prototyped by

double calculateItemCost(double itemPrice, char discountType, unsigned quantity)
Expert's answer
double calculateItemCost(double itemPrice, char discountType, unsigned quantity)
{
return itemPrice * (1 - (double)discountType / 100.) * quantity;
}

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be first!

Leave a comment

Ask Your question

Submit
Privacy policy Terms and Conditions