import sys
input = sys.stdin.readline
A, P = map(int, input().split())

print(int((3*A+P)/2)) import sys sys input = sys.stdin.readline input sys.stdin.readline sys.stdin sys stdin readline A, P = map(int, input().split()) A map(int, input().split()) map int input().split() ().split () input split P print(int((3*A+P)/2)) print int((3*A+P)/2) int (3*A+P)/2 3*A+P 3*A 3 A P 2 P = map(int, input().split()) map(int, input().split()) P A, P = map(int, input().split()) map(int, input().split()) A input = sys.stdin.readline sys.stdin.readline input
import sys
input = sys.stdin.readline
A, P = map(int, input().split())

print(int((3*A+P)/2))