from sys import stdin def main(): input = lambda: stdin.readline()[:-1] D = int(input()) A, B = map(int, input().split()) cost = float("inf") for x in range(D + 1): cost = min(cost, x * A + (D - x) * B) print(cost) main()