Taking Xn as the amount of stock at the end of week n, you need to solve the difference equation (recurrence relation)
Xn+1 = X + (1 - p
100
)Xn
Put Xn = Yn - C then choose C such that
Yn+1 = (1 - p
100
)Yn
and consider the values of this expression for Yn, Yn-1, Yn-2, ... Y1, Y0.