n = 1
d = 20
while ...:
    n = ...
    d = 1.05 * d
