import sys
import math

num = list(map(int,input().split()))

A = num[0]
P = num[1]
parts = A*3+P
print(math.floor(parts/2)) import sys sys import math math num = list(map(int,input().split())) num list(map(int,input().split())) list map(int,input().split()) map int input().split() ().split () input split A = num[0] A num[0] num 0 P = num[1] P num[1] num 1 parts = A*3+P parts A*3+P A*3 A 3 P print(math.floor(parts/2)) print math.floor(parts/2) math.floor math floor parts/2 parts 2 P = num[1] num[1] P num = list(map(int,input().split())) list(map(int,input().split())) num parts = A*3+P A*3+P parts A = num[0] num[0] A
import sys
import math

num = list(map(int,input().split()))

A = num[0]
P = num[1]
parts = A*3+P
print(math.floor(parts/2))
