a,b,c = map(int,input().split()) ans = set([]) if(c % a == 0): ans.add(c // a) if((c + b) % a == 0): ans.add((c + b) // a) if not(ans): print(-1) exit(0) for k in sorted(ans): x = k * a if(x - b > 0): x -= b if(x != c): continue print(k)