acm-mjct / Utilities

8 stars 86 forks source link

Construct a Tip Calculator #36

Open iamasrar011 opened 2 years ago

iamasrar011 commented 2 years ago

Calculate the tip value on an array of bill values depending upon the following conditions:

If the bill value is between 0 and 300, then the tip is 15% of the bill value. If the bill value is greater than 300, then the tip is 20% of the bill value. Print the bill value as well as tip value.