Measure Total Expenses | Sololearn: Learn to code for FREE!


Measure Total Expenses

While purchasing an item, discount of 10% is offered if the purchasing amount is more than 1000. If quantity and price per item are input through keyboard, write a program to calculate total expenses in c program


4/28/2018 2:51:54 PM


1 Answer

New Answer


return (n > 1000) ? n * 0.9 : n;