s = input().split(" ")
a,b = int(s[0]), int(s[1])
if (a*3 + b) % 2 == 0:
  print(int((a*3 + b)/2))
else:
  print(int((a*3 + b - 1)/2)) s = input().split(" ") s input().split(" ") ().split () input split " " a,b = int(s[0]), int(s[1]) a int(s[0]) int s[0] s 0 b int(s[1]) int s[1] s 1 if (a*3 + b) % 2 == 0:
  print(int((a*3 + b)/2))
else:
  print(int((a*3 + b - 1)/2)) (a*3 + b) % 2 == 0 (a*3 + b) % 2 a*3 + b a*3 a 3 b 2 0 print(int((a*3 + b)/2)) print int((a*3 + b)/2) int (a*3 + b)/2 a*3 + b a*3 a 3 b 2 print(int((a*3 + b - 1)/2)) print int((a*3 + b - 1)/2) int (a*3 + b - 1)/2 a*3 + b - 1 a*3 + b a*3 a 3 b 1 2 a,b = int(s[0]), int(s[1]) int(s[0]) a b = int(s[0]), int(s[1]) int(s[1]) b s = input().split(" ") input().split(" ") s
s = input().split(" ")
a,b = int(s[0]), int(s[1])
if (a*3 + b) % 2 == 0:
  print(int((a*3 + b)/2))
else:
  print(int((a*3 + b - 1)/2))