Problem: paul sells encyclopedias door - to - door . he earns $ 150 on every paycheck , regardless of how many sets he sells . in addition , he earns commission as follows : commission sales 10 % $ 0.00 - $ 10 , 000.00 5 % $ 10 , 000.01 - - - > he does not earn double commission . that is , if his sales are $ 12,000 , he earns 10 % on the first $ 10,000 and 5 % on the remaining $ 2,000 . his largest paycheck of the year was $ 1,320 . what were his sales for that pay period ?
Rationale: his pay check was $ 1320 . out of this , $ 150 was his fixed salary so the total commission he earned was $ 1320 - $ 150 = $ 1170 he earns 10 % on the sales of first $ 10,000 which gives a commission of $ 1000 . he earns 5 % on every subsequent dollar . since he earns another $ 170 , he must have had sales of another 170 * ( 100 / 5 ) = 3400 so his total sales must have been $ 10,000 + $ 3400 = $ 13,400 a
annotated_formula: divide(add(multiply(150, divide(const_100, 5)), multiply(const_100, const_100)), multiply(10, const_100))