N, A, B = map(int, input().split()) if B - A >= 0: ans = - B * N + A * (N - 1) else: ans = -A * (N - 1) - B * (N % 2) print(ans)