Shirt Xl

See More About:    Shirt Xl        

Thanks for visiting Team Sport. You could soon be saving a lot of money and even time using our website Team Sport. Do your search here for Shirt Xl and act wisely to reap the benefits. Thanks for Visiting

Frequently Asked Questions...

Write a program that gives a discount of 100 pesos to a customer if the shirt bought is XL and the price is gr?

Write a program that gives a discount of 100 pesos to a customer if the shirt bought is XL and
the price is greater than 500 pesos; a discount of 50 pesos if the shirt bought is L and the price is
greater than 400.
it C++.. please help me?


Best Answer...

Answer:

-------------------
char shirt[3];
int price = 0;
int discount_400_L = 50;
int discount_500_XL = 100;

cout << "please enter the size:n";
cin >> shirt;

cout << "please enter the price:n";
cin >> price;

if ( (price > 500) && strcmp(shirt,XL) ) price = price - discount_500_XL;
if ( (price > 400) && strcmp(shirt,L) ) price = price - discount_400_L;
-------------------