n,x,k=list(map(int,input().split(' ')))

temp=k

ans=0

while n>0:

    n-=x

    ans +=temp

    k+=k





print(ans)
n,x,k=list(map(int,input().split(' ')))



print((int((n+x-1)/x)*k))

n, x, k = list(map(int, input().split(" ")))
temp = k
ans = 0
while n > 0:
    n -= x
    ans += temp
    k += k
print(ans)

n, x, k = list(map(int, input().split(" ")))
print((int((n + x - 1) / x) * k))

-temp = k -ans = 0 -while n > 0: -    n -= x -    ans += temp -    k += k -print(ans) +print((int((n + x - 1) / x) * k))