A tennis tournament with n participants is running. The participants are playing by an olympic system, so the winners move on and the losers drop out.

The tournament takes place in the following way (below, m is the number of the participants of the current round):  let k be the maximal power of the number 2 such that k ≤ m,  k participants compete in the current round and a half of them passes to the next round, the other m - k participants pass to the next round directly,  when only one participant remains, the tournament finishes. 

Each match requires b bottles of water for each participant and one bottle for the judge. Besides p towels are given to each participant for the whole tournament.

Find the number of bottles and towels needed for the tournament.

Note that it's a tennis tournament so in each match two participants compete (one of them will win and the other will lose).


-----Input-----

The only line contains three integers n, b, p (1 ≤ n, b, p ≤ 500) — the number of participants and the parameters described in the problem statement.


-----Output-----

Print two integers x and y — the number of bottles and towels need for the tournament.


-----Examples-----
Input
5 2 3

Output
20 15

Input
8 2 4

Output
35 32



-----Note-----

In the first example will be three rounds:  in the first round will be two matches and for each match 5 bottles of water are needed (two for each of the participants and one for the judge),  in the second round will be only one match, so we need another 5 bottles of water,  in the third round will also be only one match, so we need another 5 bottles of water. 

So in total we need 20 bottles of water.

In the second example no participant will move on to some round directly.

Difficulty: interview

Starter code:

Solutions:
n, b, p = map(int, input().split())
answer1 = 0
answer2 = n
while n > 1:
    k = 1
    while k < n:
        k *= 2
    answer1 += k * b + (k // 2)
    n = k // 2 + n - k
print(answer1, answer2 * p)

n, b, p = map(int, input().split())
r1 = 0
r2 = p * n
while n != 1:
    curr = 1
    while curr * 2 <= n:
        curr *= 2
    n -= curr // 2
    r1 += curr * b + curr // 2
print(r1, r2)

n, b, p = [int(x) for x in input().split()]
b1, p1 = 0, n*p
while n > 1:
    n1 = 2 << (n.bit_length()-2)
    b1 += (2*b + 1) * n1 // 2
    n -= n1//2
print(b1, p1)


n, b, p = list(map(int, input().split()))
g1 = 2 * b + 1
g2 = 2 * p
print((n - 1) * g1, n * p)


n,b,p=map(int,input().split())
ans_b=0
ans_p=n*p
while n!=1:
    kol_m=n//2
    ans_b+=kol_m*(2*b+1)
    n=n-n//2
print(ans_b,ans_p)

import math
n, b, p = map(int, input().split())
curr = n
ans = 0
while curr != 1:
    l = 2 ** int(math.log(curr, 2))
    ans += l * b + l // 2
    curr -= (l // 2)
print(ans, n * p)

import math
from math import *
n,b,p = map(int, input().split(' '))
#n,b,p = 5,2,3
ansb = 0
ansp = p * n
while n > 1:
    t = floor(log(n)/log(2))
    m = 2**t
    ansb += (2*b + 1) * (m/2)
    n -= m/2
print(int(ansb), int(ansp))

n, b, p = map(int, input().split())
m = n
ans = 0
while m > 1:
  lb = 0
  rb = 10
  while lb != rb:
    mb = (lb + rb + 1) // 2
    if 2**mb <= m:
      lb = mb
    else:
      rb = mb - 1
  ans += (2**lb) * b + 2**(lb - 1)
  m -= 2**(lb - 1)
print(ans, n * p)

n, b, p = list(map(int, input().split()))
ansb = p * n
if n == 1:
    print(0, ansb)
else:
    k = 2
    while 2 * k <= n:
        k *= 2
    ansa = 0
    while n > 1:
        k //= 2
        ansa += b * 2 * k + k
        n -= k
        while 2 * k <= n:
            k *= 2
        while k > n:
            k //= 2
    print(ansa, ansb)


n, b, p = [int(t) for t in input().split()]
print((n-1)*(2*b+1), n*p)

n, b, p = list(map(int, input().split()))

ans1 = 0
ans2 = p * n
while n != 1:
    k = 1
    while k * 2 <= n:
        k *= 2
    ans1 += k // 2 + b * k
    n -= k // 2

print(ans1, ans2)


n, b, p = map(int, input().split())
c, v = n, 0
while c > 1:
    k = 2
    while 2 * k <= c:
        k *= 2
    c -= k // 2
    v += k * b + k // 2
print(v, n * p)

import math
n, bottles, towels = map(int, input().split())
num = n
cnt = 0
while n != 1:
    cnt += math.floor(math.log2(n))
    n -= math.floor(math.log2(n))
print(cnt * bottles * 2 + cnt, num * towels)

n, b, p = list(map(int, input().split(" ")))
dup = n
ans = 0
while n>1:
	ans += (n//2)*(2*b + 1)
	n = n//2 + n%2
print(ans, p*dup)

n,b, p = input().split();
n= int(n)
b=int(b)
p=int(p)
print((n-1)*2*b+(n-1),end=' ')
print(n*p)


def read():
  return [int(s) for s in input().split()]

(n, b, p) = read()
print((n-1)*(2*b+1), n*p)


n, b, p = [int(x) for x in input().split()]
print((2 * b + 1) * (n - 1), n * p)


import collections
import math

n, b, p = map(int, input().split())
ans, k, t = 0, 2, n
while k <= n:
    k *= 2
k //= 2
while n != 1:
    ans += (2 * b + 1) * (k // 2)
    n -= k // 2
    while k > n:
        k //= 2
print(ans, t * p)

def func(n):
    if n<2:
        return 0
    if n==2:
        return 1
    k=int(n/2)
    remain=n-k*2
    return k+func(k+remain)

inf=list(map(int,input().split()))
n,b,p=inf[0],inf[1],inf[2]
water=2*b+1
match=func(n)
print(match*water,n*p)


import queue
import math
import io


# n = int(input())
#
# class Sphere:
#     def __init__(self,x,y,r):
#         self.x = x
#         self.y = y
#         self.r = r
#         self.left =x-r
#         self.right = 300 - x+r
#
#     def has_route(self, shere):
#         return math.sqrt((self.x - shere.x)**2+(self.y-shere.y)**2) <=self.r+shere.r
#
#     def __str__(self):
#         return str(self.x)+'_'+str(self.y)+'_'+str(self.r)
#
# to_ = []
# sher = []
# sheres = {}
# sheres1 ={}
# def bfs(start):
#     q = queue.Queue()
#     q.put(start)
#     used ={}
#     d ={}
#     p ={}
#     for sher1 in sheres:
#         used[sher1]=False
#         d[sher1]=0
#         p[sher1]=0
#     used[start]=True
#     while not q.empty():
#         v = q.get()
#         for sh in sheres[v]:
#             if not used[sh]:
#                 used[sh]=True
#                 q.put(sh)
#                 d[sh]=d[v]+1
#                 p[sh]=v
#     return [used,d,p]
#
#
# for i in range(n):
#     [x,y,r] = [int(x) for x in input().split(' ')]
#     sher.append(Shere(x,y,r))
#     to_.append(sher[-1])
#     sheres1[str(sher[-1])]=sher[-1]
#
# to_.sort(key=lambda x: x.left)
#
#
#
#
# for i in range(len(sher)):
#     for j in range(len(sher)):
#         if i != j:
#             if sher[i].has_route(sher[j]):
#                 if str(sher[i]) in  sheres:
#                     sheres[str(sher[i])].append(str(sher[j]))
#                 else:
#                     sheres[str(sher[i])] = [str(sher[j])]
#             else:
#                 if str(sher[i]) not in sheres:
#                     sheres[str(sher[i])] = []
#
# [used,d,p] = bfs(str(sher[0]))
#
# print(d)
# print(p)
# print(sheres)
# print(to_)




#
# def relax(to, p):
#     v = to
#     res = []
#     while (v != -1):
#         res.append(v)
#         v = p[v]
#     return res
#
#
# [b, e, p, n, m] = [int(x) for x in input().split()]
# g = []
# for i in range(n+1):
#     g.append([])
# print(g)
# for i in range(m):
#     [to, v] = [int(x) for x in input().split()]
#     g[to].append(v)
#     g[v].append(to)
#
# [used1, d1, p1] = bfs(1, g)
# [used2, d2, p2] = bfs(2, g)
# [used3, d3, p3] = bfs(n, g)
# mi = 10 ** 10
# print(p1)
# path = relax(2,p1)
# for i in range(len(path)):
#     cur_po = path[i]
#     len_c = d3[path[i]]
#     mi = min(i*b+(len(path)-i)*e+d3[path[i]]*p, mi)
#
#
# print(min(mi, d3[1]*b+d3[2]*e))
#io1 = open('discuss.in')
s = [2,4,8,16,32,64,128,256,512]

def step(n):
    st = 0
    for i in range(len(s)):
        if(s[i]>n):
            st = s[i-1]
            break
    return [(n-st)+st//2, st//2]


[n,b,p] = [int(x) for x in input().split(' ')]
res = 0
res_p = n*p
while n > 1:
    [n, rb]= step(n)
    res+=rb*2*b+rb
print(str(res)+" "+str(res_p))

#!/usr/bin/env python
n, b, p = list(map(int, input().split()))
b_sum = 0
p_sum = p * n
import math
while n > 1:
    b_sum += (2 * b + 1) * int(math.log2(n))
    n -= int(math.log2(n))
print(b_sum, p_sum)


def __starting_point():

    n , b , p = map( int , input().split() )

    res2 = n*p
    res1 = 0
    while n > 1:
        res1 += (n//2)*(2*b+1)
        n -= n//2

    print( res1 , res2 )
__starting_point()

import math
(n, b, p) = list(map(int, input().split()))
m = n
bottles = 0
papers = p * n
while m > 1:
    k = 2 ** math.floor(math.log(m, 2))
    bottles += k * b
    bottles += k // 2
    m = m - k + k // 2
print(bottles, papers)





    


3

import math

n, b, p = [int(i) for i in input().split()]

towels = n * p
bottles = 0

def less_power2(num):
	return 2 ** int(math.log(num, 2))

m = n
while m > 1:
	k = less_power2(m)
	bottles += k*b + k//2
	m -= k // 2

print(bottles, towels)