import sys
a=sys.stdin.readline()
res = [int(i) for i in a.split() if i.isdigit()] 
A,P = [res[i] for i in (0,1)]
if type(A)==int and type(P)==int and (A>=0 and A<=100) and (P>=0 and P<=100):
    Pieces=P+(A*3)
    Pies=Pieces//2
    print(Pies)
else:
    print("Error") import sys sys a=sys.stdin.readline() a sys.stdin.readline() sys.stdin.readline sys.stdin sys stdin readline int(i) for i in a.split() if i.isdigit() for i in a.split() if i.isdigit() i a.split() a.split a split i.isdigit() i.isdigit i isdigit if i.isdigit() int(i) int i res = [int(i) for i in a.split() if i.isdigit()] res [int(i) for i in a.split() if i.isdigit()] res[i] for i in (0,1) for i in (0,1) i (0,1) 0 1 for i in (0,1) res[i] res i A,P = [res[i] for i in (0,1)] A [res[i] for i in (0,1)] P if type(A)==int and type(P)==int and (A>=0 and A<=100) and (P>=0 and P<=100):
    Pieces=P+(A*3)
    Pies=Pieces//2
    print(Pies)
else:
    print("Error") type(A)==int and type(P)==int and (A>=0 and A<=100) and (P>=0 and P<=100) type(A)==int and type(P)==int and (A>=0 and A<=100) type(A)==int and type(P)==int type(A)==int type(A) type A int type(P)==int type(P) type P int A>=0 and A<=100 A>=0 A 0 A<=100 A 100 P>=0 and P<=100 P>=0 P 0 P<=100 P 100 Pieces=P+(A*3) Pieces P+(A*3) P A*3 A 3 Pies=Pieces//2 Pies Pieces//2 Pieces 2 print(Pies) print Pies print("Error") print "Error" Pieces=P+(A*3) P+(A*3) Pieces res = [int(i) for i in a.split() if i.isdigit()] [int(i) for i in a.split() if i.isdigit()] res Pies=Pieces//2 Pieces//2 Pies P = [res[i] for i in (0,1)] [res[i] for i in (0,1)] P A,P = [res[i] for i in (0,1)] [res[i] for i in (0,1)] A a=sys.stdin.readline() sys.stdin.readline() a
import sys
a=sys.stdin.readline()
res = [int(i) for i in a.split() if i.isdigit()] 
A,P = [res[i] for i in (0,1)]
if type(A)==int and type(P)==int and (A>=0 and A<=100) and (P>=0 and P<=100):
    Pieces=P+(A*3)
    Pies=Pieces//2
    print(Pies)
else:
    print("Error")