a,b,c = tuple(map(int,input().split()))
for i in range(1,11):
    c = a * c - b
    print(c) a,b,c = tuple(map(int,input().split())) a tuple(map(int,input().split())) tuple map(int,input().split()) map int input().split() ().split () input split b c for i in range(1,11):
    c = a * c - b
    print(c) i range(1,11) range 1 11 c = a * c - b c a * c - b a * c a c b print(c) print c b,c = tuple(map(int,input().split())) tuple(map(int,input().split())) b a,b,c = tuple(map(int,input().split())) tuple(map(int,input().split())) a c = a * c - b a * c - b c c = tuple(map(int,input().split())) tuple(map(int,input().split())) c
a,b,c = tuple(map(int,input().split()))
for i in range(1,11):
    c = a * c - b
    print(c)