d = int(input()) a,b = map(int,input().split(' ')) x = 0 y = x * a + ( d - x ) *b for x in range(d+1): y = x * a + ( d - x ) *b