Forum Moderators: coopster

Message Too Old, No Replies

finding profit value from total sales amount

known values are total sales, profit percentage

         

phparion

7:41 am on Feb 12, 2022 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



hi,

it is kind of a statistics/maths question but of course programming is all mathematics :)

In my application the initial cost of a product "was" known and the a percentage of the profit was added to find the selling price. at the end of the month the total sales amount is known. Now at this stage, I have to generate profit report and have to show total profit earned. e.g

product A cost = 100
% or profit = 70%
sale price = 170
sold qty = 200
total sales = 34000

now for this simple example I know that profit earned is 14000. but how can I apply some formula on 34000 to get this 14000 of total profit?

because in actual application values are very high and the total sales is a sum of sales of hundreds of different products. to rephrase in simple words, I have total sale amount (34000 in example) and I know that sale price was found by profit percentage of (70% as in example) now how can i find the total profit from 34000? if I do simple 34000 x 70%, I get wrong answer. COST at this point is not known to me. sale prices were calculated by other people on some stage I am just given with database of sales amounts and profit percentage.

thank you

topr8

8:20 am on Feb 12, 2022 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



profit = total sales value - (total sales value / (1 + markup))

eg. from your example

34,000 - (34,000 / 1.7)

phparion

6:14 pm on Feb 12, 2022 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



you are a life saver :) . this is what I was looking for. thank you.