We have A apples and P pieces of apple.
We can cut an apple into three pieces of apple, and make one apple pie by simmering two pieces of apple in a pan.
Find the maximum number of apple pies we can make with what we have now.

-----Constraints-----
 - All values in input are integers.
 - 0 \leq A, P \leq 100

-----Input-----
Input is given from Standard Input in the following format:
A P

-----Output-----
Print the maximum number of apple pies we can make with what we have.

-----Sample Input-----
1 3

-----Sample Output-----
3

We can first make one apple pie by simmering two of the three pieces of apple. Then, we can make two more by simmering the remaining piece and three more pieces obtained by cutting the whole apple.

Difficulty: EASY

Solutions:
(k, n) = map(int, input().split())
n += k * 3
print(n // 2)


(A, P) = map(int, input().split())
n = (A * 3 + P) // 2
print(n)


(Ful, Pic) = map(int, input().split())
print((Ful * 3 + Pic) // 2)


(A, P) = map(int, input().split())
ans = (3 * A + P) // 2
print(ans)


(A, N) = map(int, input().split())
print((A * 3 + N) // 2)


(x, y) = map(int, input().split())
res = (x * 3 + y) // 2
print(res)


(A, P) = input().split()
print((3 * int(A) + int(P)) // 2)


(a, p) = (int(i) for i in input().split())
print((3 * a + p) // 2)


print(eval(input().replace(' ', '*3+')) // 2)


(N, P) = map(int, input().split())
print((N * 3 + P) // 2)


(A, P) = map(int, input().split())
p = A * 3 + P
print(p // 2)


(A, P) = (int(i) for i in input().split())
print((P + 3 * A) // 2)


(N, K) = map(int, input().split())
print((3 * N + K) // 2)


(a, p) = list(map(int, input().split()))
total_pie = (a * 3 + p) // 2
print(total_pie)


(A, P) = map(int, input().split())
ap = A * 3 + P
print(ap // 2)


(a, b) = map(int, input().split())
s = 3 * a + b
r = s // 2
print(r)


(n, m) = map(int, input().split())
print((3 * n + m) // 2)


def mapt(fn, *args):
	return tuple(map(fn, *args))

def Input():
	return mapt(int, input().split(' '))

def main():
	(a, p) = Input()
	x = a * 3 + p
	ans = x // 2
	print(ans)
main()


(A, P) = map(int, input().split())
X = A * 3 + P
print(int(X // 2))


(A, P) = map(int, input().split())
PP = 3 * A + P
print(PP // 2)


(A, P) = map(int, input().split())
c = (A * 3 + P) // 2
print(c)


(x, y) = map(int, input().split())
a = (3 * x + y) // 2
print(a)


(b, c) = map(int, input().split())
print((b * 3 + c) // 2)


(a, p) = map(int, input().split())
k = a * 3 + p
ans = k // 2
print(ans)


(n, x) = map(int, input().split())
print((n * 3 + x) // 2)


(A, P) = map(int, input().split())
Ap = 3 * A + P
print(Ap // 2)


def inputlist():
	return [int(j) for j in input().split()]
(A, P) = inputlist()
print((3 * A + P) // 2)


(A, P) = map(int, input().split())
slice = A * 3 + P
print(slice // 2)


(A, P) = map(int, input().split())
num = 3 * A + P
print(num // 2)


(A, P) = map(int, input().split())
tot = 3 * A + P
print(tot // 2)


import math
(a, p) = list(map(int, input().split()))
print(math.floor((3 * a + p) / 2))


(A, P) = input().split()
ringo = int(A) * 3
rin = ringo + int(P)
ri = rin // 2
print(ri)


(a, p) = map(int, input().split())
k = 3 * a + p
ap = k // 2
print(ap)


(a, pi) = map(int, input().split())
print((a * 3 + pi) // 2)


(A, P) = map(int, input().split())
print(A * 3 + P >> 1)


(a, b) = map(int, input().split())
c = (3 * a + b) / 2
import math
print(math.floor(c))


a = list(map(int, input().split()))
print((a[0] * 3 + a[1]) // 2)


(A, P) = map(int, input().split())
apple_fragment = A * 3 + P
apple_pie = apple_fragment // 2
print(apple_pie)


(a, p) = map(int, input().split())
m = a * 3 + p
if m % 2 == 0:
	print(m // 2)
else:
	print((m - 1) // 2)


(w, p) = map(int, input().split())
print((w * 3 + p) // 2)


(a, p) = [int(x) for x in input().split()]
print((a * 3 + p) // 2)


(A, P) = map(int, input().split())
P1 = P + 3 * A
print(P1 // 2)


(a, p) = map(int, input().split())
print(a * 3 + p >> 1)


(p, q) = map(int, input().split())
print((p * 3 + q) // 2)


(a, q) = map(int, input().split())
print((a * 3 + q) // 2)


s = input().split()
t = int(s[0]) * 3 + int(s[1])
print(t // 2)


(A, P) = map(int, input().split())
S = (3 * A + P) // 2
print(S)