d = int(input())
a,b = map(int,input().split())
#x*a + (d-x)*b のmin
MM = []
for i in range(d+1):
    MM.append(i*a + (d-i)*b)
print(min(MM))