First:

You did not use D: I suppose instead of B / 6, it should read B x D, where D can be either 20% or 16,666…%

There is a mistake: B x C is not 3.60 for the given values (B=20, C=15%), it is 3.
This is a matter of mathematical deduction:
Given the equation:
E = B – A – (B x C) – (B x D)
Add A to both sides:
E + A = B – (B x C) – (B x D)
Isolate B:
E + A = B x (1 – C – D)
Divide both sides by (1 – C – D). Condition: C + D cannot equal 100%
(E + A) / (1 – C – D) = B
So there is your formula for calculating B. Take note of the condition: this only holds true when C + D is not equal to 100%.
0
solved Maths Two Percentage Increases – Any Takers