Problem:
 Score : 100 points    Problem Statement 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 1 3      Sample Output 1 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.       Sample Input 2 0 1      Sample Output 2 0  We cannot make an apple pie in this case, unfortunately.       Sample Input 3 32 21      Sample Output 3 58

Solution (Python):
import sys
import heapq
import re
from itertools import permutations
from bisect import bisect_left, bisect_right
from collections import Counter, deque
from math import factorial, sqrt, ceil, gcd
from functools import lru_cache, reduce
from decimal import Decimal
from operator import mul

INF = 1 << 60
MOD = 1000000007
sys.setrecursionlimit(10 ** 7)



class UnionFind():
    def __init__(self, n):
        self.n = n
        self.parents = [-1] * n

    def find(self, x):
        if self.parents[x] < 0:
            return x
        else:
            self.parents[x] = self.find(self.parents[x])
            return self.parents[x]

    def union(self, x, y):
        x = self.find(x)
        y = self.find(y)

        if x == y:
            return

        if self.parents[x] > self.parents[y]:
            x, y = y, x

        self.parents[x] += self.parents[y]
        self.parents[y] = x

    def size(self, x):
        return -self.parents[self.find(x)]

    def same(self, x, y):
        return self.find(x) == self.find(y)

    def members(self, x):
        root = self.find(x)
        return [i for i in range(self.n) if self.find(i) == root]

    def roots(self):
        return [i for i, x in enumerate(self.parents) if x < 0]

    def group_count(self):
        return len(self.roots())

    def all_group_members(self):
        return {r: self.members(r) for r in self.roots()}

    def __str__(self):
        return '\n'.join('{}: {}'.format(r, self.members(r)) for r in self.roots())


def dijkstra_heap(s, edge, n):
    
    d = [10**20] * n
    used = [True] * n 
    d[s] = 0
    used[s] = False
    edgelist = []
    for a,b in edge[s]:
        heapq.heappush(edgelist,a*(10**6)+b)
    while len(edgelist):
        minedge = heapq.heappop(edgelist)
        
        if not used[minedge%(10**6)]:
            continue
        v = minedge%(10**6)
        d[v] = minedge//(10**6)
        used[v] = False
        for e in edge[v]:
            if used[e[1]]:
                heapq.heappush(edgelist,(e[0]+d[v])*(10**6)+e[1])
    return d


def factorization(n):
    arr = []
    temp = n
    for i in range(2, int(-(-n**0.5//1))+1):
        if temp%i==0:
            cnt=0
            while temp%i==0:
                cnt+=1
                temp //= i
            arr.append([i, cnt])

    if temp!=1:
        arr.append([temp, 1])

    if arr==[]:
        arr.append([n, 1])

    return arr


def combinations_count(n, r):
    if n < r:
        return 0
    r = min(r, n - r)
    numer = reduce(mul, range(n, n - r, -1), 1)
    denom = reduce(mul, range(1, r + 1), 1)
    return numer // denom


def lcm(x, y):
    return (x * y) // gcd(x, y)


def lcm_list(numbers):
    return reduce(lcm, numbers, 1)


def gcd_list(numbers):
    return reduce(gcd, numbers)


def is_prime(n):
    if n <= 1:
        return False
    p = 2
    while True:
        if p ** 2 > n:
            break
        if n % p == 0:
            return False
        p += 1
    return True



def eratosthenes(limit):
    A = [i for i in range(2, limit+1)]
    P = []

    while True:
        prime = min(A)
        
        if prime > sqrt(limit):
            break
            
        P.append(prime)
            
        i = 0
        while i < len(A):
            if A[i] % prime == 0:
                A.pop(i)
                continue
            i += 1
            
    for a in A:
        P.append(a)
            
    return P


def permutation_with_duplicates(L):

    if L == []:
        return [[]]

    else:
        ret = []

        
        S = sorted(set(L))

        for i in S:

            data = L[:]
            data.remove(i)

            for j in permutation_with_duplicates(data):
                ret.append([i] + j)

        return ret

def make_divisors(n):
    lower_divisors , upper_divisors = [], []
    i = 1
    while i*i <= n:
        if n % i == 0:
            lower_divisors.append(i)
            if i != n // i:
                upper_divisors.append(n//i)
        i += 1
    return lower_divisors + upper_divisors[::-1]


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

Solution (Python):
a, p = map(int, input().split())

available = p + (a * 3)
print(int(available/2))

Solution (Python):
a, p = map(int, input().split())

print(((a*3) + p ) // 2)

Solution (Python):
A,P=map(int,input().split())

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

Solution (Python):
a, p = map(int, input().split())
print((a*3+p)//2)

Solution (Python):
a,p=map(int,input().split())

ans=(3*a+p)//2
print(ans)

Solution (Python):
a, b = map(int, input().split())
c = 0
if b>=2:
    d = b // 2
    c += d
e = b % 2
f = a * 3
g = f+e
h = g // 2
c += h
print(c)

Solution (Python):
A,B=map(int,input().split())
print((A*3+B)//2)

Solution (Python):
a, p = map(int, input().split())
n_piece = 3*a + p
print(n_piece//2)

Solution (Python):
a, p = map(int, input().split())
print((3 * a + p) // 2)

Solution (Python):
a,p = map(int,input().split())
p += a*3
print(p//2)

Solution (Python):
a,b = tuple(map(int,input().split()))
c = (a*3 + b )//2
print(c)

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

Solution (Python):
a,p=map(int, input().split())
print((3*a+p)//2)

Solution (Python):

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

Solution (Python):
a, p = map(int, input().split())

print((a * 3 + p) // 2)

Solution (Python):
a,p = map(int,input().split())
print((a*3+p)//2)

Solution (Python):
a, p = map(int, input().split())
print((a * 3 + p) // 2)

Solution (Python):
a,p=map(int,input().split())
print((a*3+p)//2)

Solution (Python):
a, p = map(int,input().split())
print((3*a+p)//2)

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

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

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

Solution (Python):
a, p = map(int, input().split())
print((3*a+p)//2)

Solution (Python):
x,y=input().split()
x=int(x)
y=int(y)
z=int((x*3+y)/2)
print(z)

Solution (Python):
a,p=map(int,input().split())

print((a*3+p)//2)

Solution (Python):
a, p = map(int, input().split())
print((3*a+p)//2)

Solution (Python):


a, p = map(int, input().split())

print(((a * 3) + p) // 2)

Solution (Python):


a,p = map(int, input().split())

print(int((a*3+p)//2))

Solution (Python):
a,p = map(int, input().split())
print((a*3+p)//2)

Solution (Python):
a,p=map(int,input().split())
print(((a*3)+p)//2)

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

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

Solution (Python):
a,p = map(int,input().split())
print((a*3+p)//2)

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

Solution (Python):

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

c = n[0]*3 + n[1]
print(c//2)

Solution (Python):
A,P=map(int,input().split())

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

Solution (Python):
a,b=map(int,input().split());print((a*3+b)//2)

Solution (Python):
a,p = map(int,input().split())
print((3*a+p)//2)

Solution (Python):
A, P = map(int,input().split())
answer = (A*3 + P)//2
print(answer)

Solution (Python):
A, P = map(int,input().split())

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

Solution (Python):
a, p = map(int, input().split())
r = a * 3 + p
t = r//2
print(t)

Solution (Python):
x, y = input("").split(" ")
a = int(x)
y = int(y)
print(int((3*a + y)/2))

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

Solution (Python):
A, B = map(int,input().split())
val = A * 3 + B
print(val//2)

Solution (Python):
def main():
    a, p = map(int, input().split())
    print(((a*3)+p)//2)
main()

Solution (Python):
a, p = map(int, input().split())
print ((3 * a + p) // 2)

Solution (Python):
a, p = map(int, input().split())
print((3*a + p) // 2)

Solution (Python):
try:
    a,p=map(int, input().split())
    assert 0<=a,p<=100
    print(((a*3)+p)//2)
except AssertionError:
    print('')

Solution (Python):
import sys

A, P = input().split()

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

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

Solution (Python):
a,p=map(int,input().split())
total=3*a+p
pies=total//2
print(pies)

Solution (Python):
a, p = map(int, input().split())
print((3 * a + p) // 2)

Solution (Python):
A, P = map(int, input().split())

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

Solution (Python):
arr = input().split()
a = int(arr[0])
p = int(arr[1])

print((a*3 + p)//2)

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

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

Solution (Python):
import sys
sys.setrecursionlimit(10**6)



a, p = map(int, input().split())








ans = (3*a+p)//2
print(ans)

Solution (Python):
a, p = map(int,input().split())
all = a * 3 + p
print(all//2)

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

Solution (Python):
import math

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

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

Solution (Python):
inp=input()
list=inp.split()
a, p=list[0], list[1]
print(int(((int(a)*3)+int(p))/2))

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

Solution (Python):
a,p=map(int,input().split())
print((a*3+p)//2)

Solution (Python):

a,p=map(int,input().split())

print((a*3+p)//2)

Solution (Python):


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

Solution (Python):


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

Solution (Python):
def MI():
    return map(int, input().split())

def LI():
    return list(map(int, input().split()))

A, P = MI()

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

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

Solution (Python):
a, p = map(int, input().split())
pieces = a*3 + p
print(pieces//2)

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

Solution (Python):
import sys

read = sys.stdin.read
readline = sys.stdin.readline
readlines = sys.stdin.readlines
sys.setrecursionlimit(10 ** 9)
INF = 1 << 60


def main():
    A, P = map(int, readline().split())

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


if __name__ == '__main__':
    main()

Solution (Python):
A, P = map(int, input().split())

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

Solution (Python):
A,P=map(int,input().split())

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

Solution (Python):
def solve():
    a, p = map(int, input().split())
    print((a*3 + p)//2)

if __name__ == '__main__':
    solve()

Solution (Python):

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

Solution (Python):
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")

Solution (Python):
A, P= list(map(int,input().split()))

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

Solution (Python):
l = [int(i) for i in input().split() if i.isdigit()]
print(int((3 * l[0] + l[1]) / 2))

Solution (Python):
a,b= input().split()
a= int(a)
b=int(b)
b= b + 3*a
c= b//2
print(c)

Solution (Python):
A, P = (int(x) for x in input().split())
print((A*3+P)//2)

Solution (Python):
a,p = map(int,input().split())

p += a*3

print(p // 2)

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

Solution (Python):
x,y = [int(x) for x in input().split()]

print((x*3+y)//2)

Solution (Python):
a, p = map(int, input().split())
a *= 3
b = a + p
b //= 2
print(b)

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

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

Solution (Python):
A,P = map(int,input().split())

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

Solution (Python):
a,p = map(int,input().split())

print((p + 3 * a) // 2)

Solution (Python):
a,p=map(int,input().split())
print((a*3+p)//2)

Solution (Python):
A, P = map(int, input().split())

M = 3*A + P
print(M//2)

Solution (Python):
a, p = map(int, input().split())
print((a*3+p)//2)

Solution (Python):
A, P = map(int, input().split())

x = A*3 + P

print(x//2)

Solution (Python):
A, P = map(int, input().split())
P += A * 3

print(P // 2)

Solution (Python):
a, p = map(int, input().split())

n = a * 3 + p
print(n//2)

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

Solution (Python):
a, p = map(int, input().split())
print((a * 3 + p) // 2)

Solution (Python):
a, p = map(int, input().split())

p += a*3

ans = p//2

print(ans)

Solution (Python):


A,P=map(int, input().split())

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

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

Solution (Python):
def main():
    a,p=map(int,input().split())
    p+=3*a
    print(p//2)
    
if __name__ == "__main__":
    main()

Solution (Python):
import sys

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

Solution (Python):
a,p=map(int,input().split())
print((p+a*3)//2)

Solution (Python):
a,p=map(int,input().split())
print((a*3+p)//2)

Solution (Python):
A, P = map(int, input().split())

import math
print(math.floor((3*A + P)/2))

Solution (Python):
a,p=map(int,input().split());print((3*a+p)//2)

Solution (Python):
import sys

input = lambda: sys.stdin.readline().rstrip()


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


if __name__ == '__main__':
    solve()

Solution (Python):
from sys import stdin, setrecursionlimit


def main():
    input = stdin.buffer.readline
    a, p = map(int, input().split())
    print((3 * a + p) // 2)


if __name__ == "__main__":
    setrecursionlimit(10000)
    main()

Solution (Python):
a,p = map(int,input().split())
print(((a*3)+p)//2)

Solution (Python):
a,b= map(int, raw_input().split(' '))
print (3*a + b)/2

Solution (Python):
a,b=map(int,input().split())
p=a*3+b
print(p//2)

Solution (Python):
a,p=map(int,input().split())
print(int((a*3+p)/2))

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

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

Solution (Python):
def main():
    a, p = map(int, input().split())
    ap = a * 3 + p 
    pp = ap // 2
    print(pp)
    
if __name__ == '__main__':
    main()

Solution (Python):
a,p = map(int,input().split())
print((3*a+p)//2)

Solution (Python):
a, p = map(int, input().split())

a *= 3

ans = (a+p)/2

print(int(ans))

Solution (Python):
import math
def ip():return int(input())
def inp():return map(int,input().split())
def linp():return list(map(int,input().split()))

a,p=inp()
print((a*3+p)//2)

Solution (Python):
a,p = map(int,input().split())
p += a*3
print(p//2)

Solution (Python):
a, p = map(int, input().split())
print((a*3+p)//2)

Solution (Python):
def getN():
    return int(input())


def getNM():
    return map(int, input().split())


def getList():
    return list(map(int, input().split()))


from collections import defaultdict, deque
from sys import exit
import math
import copy
from bisect import bisect_left, bisect_right
from heapq import *
import sys


INF = 10 ** 17
MOD = 1000000007

from fractions import *


def inverse(f):
    
    return 1 / f


def combmod(n, k, mod=MOD):
    ret = 1
    for i in range(n - k + 1, n + 1):
        ret *= i
        ret %= mod

    for i in range(1, k + 1):
        ret *= pow(i, mod - 2, mod)
        ret %= mod

    return ret


def bunsu(n):
    ret = []
    for i in range(2, int(math.sqrt(n)) + 1):
        if n % i == 0:
            tmp = 0
            while (True):
                if n % i == 0:
                    tmp += 1
                    n //= i
                else:
                    break
            ret.append((i, tmp))

    ret.append((n, 1))
    return ret

MOD = 998244353
def solve():
    n, m = getList()
    print((n * 3 + m) // 2)

def main():
    n = getN()
    for _ in range(n):
        solve()


if __name__ == "__main__":
    solve()

Solution (Python):
a, p = map(int, input().split())

p+=a*3
print(p//2)

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

Solution (Python):
A,P = map(int,input().split())
P = P+3*A

print(P//2)

Solution (Python):
a,p = map(int,input().split())

print((3*a+p)//2)

Solution (Python):
a,p = map(int, input().split())

print((a*3+p)//2)

Solution (Python):
from statistics import median


from fractions import gcd
from itertools import combinations 
from collections import deque
from collections import defaultdict
import bisect










import sys
sys.setrecursionlimit(10000000)
mod = 10**9 + 7

def readInts():
  return list(map(int,input().split()))
def I():
  return int(input())
a,p = readInts()
print((a*3 + p)//2)

Solution (Python):
a,p=map(int,input().split())
print((a*3+p)//2)

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

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

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

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

Solution (Python):
a,p = map(int, input().split())
print((a*3+p)//2)

Solution (Python):
a, p = map(int, input().split())
print((3*a+p)//2)

Solution (Python):
A, P = map(int, input().split())

ans = (A*3 + P) //2

print(ans)

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import accumulate, permutations, combinations, product
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

A, P = MAP()

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

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

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

Solution (Python):
a,p = map(int,input().split())
p = p + (a * 3)
print(p // 2)

Solution (Python):
a,p=map(int,input().split())
print((3*a+p)//2)

Solution (Python):
a,p=map(int,input().split())
print(int((a*3+p)/2))

Solution (Python):
A,P=map(int,input().split())

X=A*3+P

print(int(X/2))

Solution (Python):
a, p = map(int, input().split())

print((3 * a + p) // 2)

Solution (Python):
a,p = map(int,input().split())
a *= 3
print((a+p)//2)

Solution (Python):
a, p = map(int, input().split())
print((a*3+p)//2)

Solution (Python):
a,p = map(int,input().split())
sum = a*3 + p
print(sum//2)

Solution (Python):
a,b=map(int,input().split())
print((3*a+b)//2)

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

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

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

Solution (Python):
a, p = map(int, input().split())
print((3*a+p) // 2)

Solution (Python):
import sys
input = lambda : sys.stdin.readline().rstrip()

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

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

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

Solution (Python):
import math
A, P = map(int, input().split())
pie = 0.5 * (P + 3 * A)
realPie = math.floor(pie)
print(realPie)

Solution (Python):
def resolve():
    A, P = map(int, input().split())
    print((3*A + P)//2)
resolve()

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

Solution (Python):
a,p=map(int,input().split())
print((a*3+p)//2)

Solution (Python):
a, p = map(int, input().split())
z = 3*a+p
print(int(z/2))

Solution (Python):
a, p = map(int, input().split())
num = 3*a + p
print(num//2)

Solution (Python):
import sys
input=sys.stdin.readline
sys.setrecursionlimit(10 ** 8)
from itertools import accumulate
from itertools import permutations
from itertools import combinations
from collections import defaultdict
from collections import Counter
import fractions
import math
from collections import deque
from bisect import bisect_left
from bisect import insort_left
import itertools
from heapq import heapify
from heapq import heappop
from heapq import heappush
import heapq
from copy import deepcopy
alf = list("abcdefghijklmnopqrstuvwxyz")
ALF = list("ABCDEFGHIJKLMNOPQRSTUVWXYZ")

INF = float("inf")











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

Solution (Python):
a, p = map(int,input().split())
p += a * 3
print(p // 2)

Solution (Python):
a,p=map(int,input().split())
print(int((a*3+p)/2))

Solution (Python):
A, P = map(int, input().split())
kakera =3*A+P
print(kakera//2)

Solution (Python):
def resolve():
    A, P = map(int, input().split())

    ans = (A * 3 + P) // 2

    print(ans)


resolve()

Solution (Python):
a, p = map(int, input().split())

p += a*3

print(int(p/2))

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

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

Solution (Python):
a, p = map(int, input().split())
print((a*3+p)//2)

Solution (Python):
a,p=map(int,input().split())
result=(p+(a*3)) // 2
print(result)

Solution (Python):
A, P = map(int, input().split())

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

Solution (Python):
def main():
  num = list(map(int,input().split()))
  print(int((num[0]*3+num[1])/2))

main()

Solution (Python):
a, p = map(int, input().split())
print((a*3+p)//2)

Solution (Python):
a,p = map(int,input().split())

p = p + a*3

print(int(p/2))

Solution (Python):
a,p = map(int,input().split())
print((a*3+p)//2)

Solution (Python):


a, p = list(map(int, input().split()))

print((a*3+p)//2)

Solution (Python):
from collections import defaultdict, deque
import sys


def LI(): return list(map(int, sys.stdin.buffer.readline().split()))
def I(): return int(sys.stdin.buffer.readline())
def LS(): return sys.stdin.buffer.readline().rstrip().decode('utf-8').split()
def S(): return sys.stdin.buffer.readline().rstrip().decode('utf-8')
def IR(n): return [I() for i in range(n)]
def LIR(n): return [LI() for i in range(n)]
def SR(n): return [S() for i in range(n)]
def LSR(n): return [LS() for i in range(n)]
def SRL(n): return [list(S()) for i in range(n)]
def MSRL(n): return [[int(j) for j in list(S())] for i in range(n)]


a, p = LI()
sums = 3 * a + p
print(sums // 2)

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

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

Solution (Python):
from sys import stdin
def LI(): return list(map(int,stdin.readline().rstrip().split()))

tmp = LI()
a,p = [tmp.pop(0) for _ in range(2)]
ans = int((3*a+p)/2)
print(ans)

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

Solution (Python):
a, p = map(int, input().split())
print((a * 3 + p) // 2)

Solution (Python):
a,p=[int(x) for x in input().split()]

c=a*3+p

print(c//2)

Solution (Python):
a,p = map(int,input().split())
ans = 0
ans += (3 * a + p)// 2
print(ans)

Solution (Python):
a,p = map(int,input().split())
p = 3*a + p
print(p//2)

Solution (Python):
a,p = map(int,input().split())

print((3*a+p)//2)

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

Solution (Python):



def main():
    a, p = map(int, input().split())
    print((a * 3 + p) // 2)


if __name__ == '__main__':
    main()

Solution (Python):

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

Solution (Python):
a,p = map(int,input().split())
print((a*3+p)//2)

Solution (Python):

A, P = map(int, input().split())

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

Solution (Python):
import math
a,p = map(int,input().split())

print(math.floor((a*3+p)/2))

Solution (Python):
from math import floor
a, p = map(int, input().split())

print(int(floor((3*a+p)/2)))

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

Solution (Python):
a,p=map(int,input().split())
print(((3*a)+p)//2)

Solution (Python):
a,p=map(int,input().split())
apple=a*3+p
print(apple//2)

Solution (Python):
A,P=map(int,input().split());print((A*3+P)//2)

Solution (Python):
a,p=map(int,input().split())
print((a*3+p)//2)

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

Solution (Python):
print(eval("3*"+input().replace(" ","+"))//2)

Solution (Python):
a,p=map(int,input().split());print((a*3+p)//2)

Solution (Python):
a,p = map(int,input().split())

print((a*3+p)//2)

Solution (Python):
a,p=map(int,input().split());print((a*3+p)//2)

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

Solution (Python):
A, P = map(int, input().split())

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

Solution (Python):
a, p = map(int, input().split())
print((a*3+p)//2)

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

Solution (Python):
a, p = map(int, input().split())

print((a*3+p)//2)

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

Solution (Python):
import sys
import math
import itertools
a,p=map(int,input().split())
p+=a*3
print(p//2)

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

Solution (Python):
a,p = map(int,input().split())
print((a*3+p)//2)

Solution (Python):
A,P = list(map(int, input().split()))
print( (3*A+P)//2 )

Solution (Python):

import sys
import math
from bisect import bisect_left, bisect_right, insort_left, insort_right
from collections import defaultdict, deque, Counter
from copy import deepcopy
from fractions import gcd
from functools import lru_cache, reduce
from heapq import heappop, heappush
from itertools import accumulate, groupby, product, permutations, combinations, combinations_with_replacement
from math import ceil, floor, factorial, log, sqrt, sin, cos
from operator import itemgetter
from string import ascii_lowercase, ascii_uppercase, digits
sys.setrecursionlimit(10**6)
INF = float('inf')
MOD = 10 ** 9 + 7
def rs(): return sys.stdin.readline().rstrip()
def ri(): return int(rs())
def rf(): return float(rs())
def rs_(): return [_ for _ in rs().split()]
def ri_(): return [int(_) for _ in rs().split()]
def rf_(): return [float(_) for _ in rs().split()]
def divisors(n, sortedresult=True):
    div = []
    for i in range(1, int(n**0.5)+1):
        if n % i == 0:
            div.append(i)
            if i != n // i:
                div.append(n//i)
    if sortedresult:
        div.sort()
    return div

A, P = ri_()
print((P + 3 * A) // 2)

Solution (Python):
import sys
readline = sys.stdin.buffer.readline
sys.setrecursionlimit(10 ** 8)
INF = float('inf')
MOD = 10 ** 9 + 7

def main():
    A, P = map(int, readline().split())
    print((3*A+P)//2)

if __name__ == '__main__':
    main()

Solution (Python):
a,p = map(int, input().split())
al = a*3 + p
print(al//2)

Solution (Python):
a, p = map(int, input().split())

ans = (a * 3 + p) // 2
print(ans)

Solution (Python):
a,p = map(int,input().split())
print((3*a + p)//2)

Solution (Python):
a, p = map(int, input().split())
print((a * 3 + p) // 2)

Solution (Python):
A, P = map(int, input().split())

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

Solution (Python):
a,p=map(int,input().split())
print((a*3+p)//2)

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

Solution (Python):
a,p=map(int,input().split())
x=a*3+p
print(x//2)

Solution (Python):
a,p=map(int,input().split())

print((a*3+p)//2)

Solution (Python):
def main():
    a, p = map(int, input().split())
    x = p + 3*a
    print(x//2)

if __name__ == "__main__":
    main()

Solution (Python):
a, p = map(int, input().split())
p += a * 3
print(p // 2)

Solution (Python):
a, p = list(map(int, input().split()))





total = a*3+p
ans = total/2
print(int(ans))

Solution (Python):
a,p = map(int,input().split())
print((a*3+p)//2)

Solution (Python):

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

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

Solution (Python):
A, P = map(int, input().split())
print (int(0.5*(A*3+P)))

Solution (Python):
a, b = map(int, input().split())

print((3*a+b)//2)

Solution (Python):
a,p=map(int,input().split())
p+=3*a

print(p//2)

Solution (Python):
def main():
    A,P=map(int,input().split())
    PieceNum=(A*3)+P
    maxPie=PieceNum//2

    print(maxPie)

if __name__=="__main__":
    main()

Solution (Python):
a,p=map(int,input().split())
print((a*3+p)//2)

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

Solution (Python):
a,p = map(int,input().split())
print ((p+(a*3))//2)

Solution (Python):
from collections import Counter 
from collections import defaultdict
from collections import deque
import math
import itertools
import heapq
import sys
sys.setrecursionlimit(10**6)




input_list = lambda : list(map(int,input().split()))

a,p=input_list()
print((a*3+p)//2)

Solution (Python):
a,p=map(int,input().split())
sum=3*a+p
print(sum//2)

Solution (Python):
A, P = map(int, input().split())

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

Solution (Python):
a,p = map(int, input().split())

print((3*a+p)//2)

Solution (Python):
A, P = list(map(int, input().split()))

a = A * 3 + P
ans = a // 2
print(ans)

Solution (Python):
import itertools
import math
import fractions
import functools
import copy
a, p = map(int, input().split())
print((a*3+p)//2)

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

Solution (Python):
a,b=map(int,input().split())
b+=a*3
print(b//2)

Solution (Python):
a,p=map(int,input().split())

print((3*a+p)//2)

Solution (Python):
def main():
    A, P = map(int, input().split())
    print((A * 3 + P) // 2)


if __name__ == '__main__':
    main()

Solution (Python):
A,P = map(int,input().split())

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

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

Solution (Python):
a, p = map(int, input().split())
print((a * 3 + p) // 2)