The local tshirt shop sells shirts retail for 12 Quantity di
Solution
Here is the code for you:
#include <iostream>
 #include <iomanip>
 #define COST_PER_SHIRT 12
 using namespace std;
 int main()
 {
 int numOfShirts;
 cout<<\"How many shirts would you like? \";
 cin>>numOfShirts;
 if(numOfShirts < 0)
 cout<<\"Invalid Input: Please enter a nonnegative integer.\"<<endl;
 else if(numOfShirts <= 4)
 cout<<\"The cost per shirt is $\"<<COST_PER_SHIRT<<\" and the total cost is $\"<<fixed<<setprecision(2)<<COST_PER_SHIRT * numOfShirts<<endl;
 else if(numOfShirts <= 10)
 cout<<\"The cost per shirt is $\"<<COST_PER_SHIRT * 0.90<<\" and the total cost is $\"<<fixed<<setprecision(2)<<COST_PER_SHIRT * numOfShirts * 0.90<<endl;
 else if(numOfShirts <= 20)
 cout<<\"The cost per shirt is $\"<<COST_PER_SHIRT * 0.85<<\" and the total cost is $\"<<fixed<<setprecision(2)<<COST_PER_SHIRT * numOfShirts * 0.85<<endl;
 else if(numOfShirts <= 30)
 cout<<\"The cost per shirt is $\"<<COST_PER_SHIRT * 0.80<<\" and the total cost is $\"<<fixed<<setprecision(2)<<COST_PER_SHIRT * numOfShirts * 0.80<<endl;
 else
 cout<<\"The cost per shirt is $\"<<COST_PER_SHIRT * 0.75<<\" and the total cost is $\"<<fixed<<setprecision(2)<<COST_PER_SHIRT * numOfShirts * 0.75<<endl;
 }
And the output screenshot is:

