r,d,x = map(int, raw_input().split(' '))
q = 10
while(q):
  x = r*x - d
  print x
  q-=1 r,d,x = map(int, raw_input().split(' ')) r map(int, raw_input().split(' ')) map int raw_input().split(' ') ().split () raw_input split ' ' d x q = 10 q 10 while(q):
  x = r*x - d
  print x
  q-=1 q x = r*x - d x r*x - d r*x r x d print q-=1 q 1 x = map(int, raw_input().split(' ')) map(int, raw_input().split(' ')) x x = r*x - d r*x - d x q-=1 1 q r,d,x = map(int, raw_input().split(' ')) map(int, raw_input().split(' ')) r d,x = map(int, raw_input().split(' ')) map(int, raw_input().split(' ')) d q = 10 10 q
r,d,x = map(int, raw_input().split(' '))
q = 10
while(q):
  x = r*x - d
  print x
  q-=1