#46150: python高中生解


chenwei980503@gmail.com (陳維(Z))


a, b, c=map(int, input().split())
d=[i for i in range(1, a+1)]
start=0
for i in range(c):
index=(start+b-1)%len(d)
d.pop(index)
start=index%len(d)
print(d[start])

# AC (2.1s, 11.2MB)