TnT/Multi_CodeNet4Repair huggingface dataset:
Problem: 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.

Submission attempts (in order):
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 // 3)


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)


Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):

N = int(input().strip())


grid = []
for i in range(N):
    array = list(input().strip().split())
    grid.append(array)
    grid[i][1]=int(grid[i][1])
print(grid)
agrid=sorted(grid)
for i in range(N-1):
  if agrid[i][0]==agrid[i+1][0] and agrid[i][1]<agrid[i+1][1]:
    b=agrid[i+1]
    c=agrid[i]
    agrid[i]=b
    agrid[i+1]=c
for i in range(N):
  print(agrid[i][1])

x=input()
xx=x.split()
A=xx[0]
P=xx[1]
a=(A*3+P)/2
print(a)

x=input()
xx=x.split()
A=int(xx[0])
P=int(xx[1])
a=(A*3+P)/2
print(int(a))

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
a=list(map(int,input().split()))

print((3*a_1+a_2)%2)

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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
a, p = map(int, input().split())
apple = a*3 + p
return int(apple/2)

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

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


Verdicts: Runtime Error

Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
a,p=[int(i)for i in input().split()]
apple=a+p//3
print(apple//2)

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
a, p = [int(a) for a in input().split()]

c = 3 * a + p

result = int(p / 2)

print(result)

a, p = [int(a) for a in input().split()]

c = 3 * a + p

result = int(c / 2)

print(result)

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
A, P = map(int, input())

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

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

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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
a,b=input().split()
a=int(a)
b=int(b)
print(int(a*3+b)/2)

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

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

Verdicts: Wrong Answer

Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
A, P = map(int, input().split())
X = 3*A + P
Y = (3*A + P) % 2
print((X - Y)/2)

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
a, p = input().split()
print((a*3 + p) // 2)

a, p = input().split()
ptint((a*3 + p) // 2)

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

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
import math
A,P=map(int, input().split())
print(math.floor((3*a+P)/2))

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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
print((lambda x,y:(x*3+y)//3)(*map(int, input().split())))

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
a, p = map(int, input().split())
print((a * 3) // 2)

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

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

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
a,p=map(int,input().split())
print(3*a+p)

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
a,p=map(int,input().split())
print((a*3+p)/2)

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
first=input()
(A, P)=first.split()
A=int(A)
P=int(P)
x=3*A
y=(x+P)/2
print(y)

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
a,p = map(int, input().split())
parts = ((a*3)+p)
print(parts/2)

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
a, p = map(int, input().split())

apple = 3 * a + b
pie = apple // 2

print(pie)

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

apple = 3 * a + p
pie = apple // 2

print(pie)

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
n=int(input())
q=[input().split() + [i] for i in range(n)]
for i in range(n):
    q[i][1]=int(q[i][1])
list_point = sorted(q, key=lambda x:x[1], reverse=1)
list_city = sorted(list_point, key=lambda x:x[0], reverse=0)
for s,t,r in list_city:
    print(r+1)
    

A, P = (int(i) for i in input().split()) 

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

A, P = [int(i) for i in input().split()]
print(A*3+P//2)

A,P = (int(i) for i in input().split()) 

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

A, P = [int(i) for i in input().split()]
print((A*3+P)//2)

Verdicts: Runtime Error

Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
n = int(input())
s_p_list = []

for i in range(n):
    s_p_list.append(input().split())
    s_p_list[i].append(i+1)

result = sorted(s_p_list, key=lambda x: (x[0], -int(x[1]))) 

for i in result:
  print(i[2])

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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
a,p=map(int,input().split())
s=a*3
reuslt=(p+s)//2

print(result)

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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
a, p = map(int(), input().split())
print(int((3*a+p)/2))

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

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

print("{}".format(ans))

N = int(input())
a = []
for i in range(N):
    s, p = input().split()
    p = -int(p)
    a.append(s, p , i + 1)
    
a.sort()

print('\n'.join(str(ai[2]) for ai in a))

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

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

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

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

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

Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
a, p = map(int, input().split())
print((a*3+p)//3)

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


Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
a,p=map(int, input().split())
print(a*3+p//2)

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

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

a,b=input().split()

apple_peace = int(a) * 3
total_peace = int(b) + int(apple_peace)

if total_peace > 1:
  pie = total_peace / 2
  print(pie)

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

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


Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
a,b = map(int,input().split())
print(int((a*3+b)/3))

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
import numpy as np





import numpy as np


# In[0] = A, [1] = P
In = list(map(int, input().split()))

A = In[0]
P = In[1]

piece = 3*A + P
pie = int(piece/2)

print(pie)




Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
a,p=map(int,input().split())↲
print(int((a*3+p)/2))


a,b=map(int,input().split())↲
d=0
c=a*3
if c>=1:
  d=(c+b)//2
elif c==0 and b>1:
  d=b//2
print(d)↲


a,b=int(input().split())↲
c=a*3
d=c+d/2

print(d)↲

a,b=map(int,input().split())↲
c=a*3
d=c+d/2
print(d)↲

a,b=map(int,input().split())↲
d=0
c=a*3
if c>1:
    d=(c+b)//2
elif c==0 and b>1:
    d=b//2
print(d)↲


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

a,b=map(int,input().split())↲
d=0
c=a*3
if c>1:
  d=(c+b)//2
print(d)↲

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

a,b=map(int,input().split())↲
d=0
c=a*3
if b>1:
  d=(c+b)//2
print(d)↲

A,P=map(int,input().split())↲
d=0
c=A*3
if c>1:
  d=(c+P)//2
elif c==0 and P>1:
  d=P//2
print(d)↲

A,P=map(int,input().split())↲
N=0↲
a=A*3↲
if a>1:
  N=(a+P)//2
elif a==0 and P>1:
  N=P//2
print(N)

a,b=map(int,input().split())↲
d=0
c=a*3
if c>1:
  d=(c+b)//2
elif c==0 and b>1:
  d=b//2
print(d)↲

a,b=map(int,input().split())
d=0
c=a*3
if c>=1:
    d=(c+b)//2
elif c==0 and b>1:
    d=b//2
print(int(d))

Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
a､b= map(int,input().split())
apple_pie = (a*3 + b) //2
print(apple_pie)

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


Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
# input
A, P = map(int, input().split())
print(3 * A + P // 2)

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
a,p = map(int, input().split())
b = a*2+p
print(b//2)

a,p = map(int, input().split())
b = a*2+p
print(b%2)

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

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):

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


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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
def main():

    N = int(input())
    if 0 > N or N > 100:
        print("input N error")
        exit()
        
    a = []
    for i in range(N):
        b = input().split()
        if len(b[0]) > 10 or len(b[0]) < 1:
            print("input S error")
            exit()

        if int(b[1]) < 0 or int(b[1]) > 100:
            print("input P error")
            exit()

        b.append(i + 1)
        a.append(b)
        
    a.sort()
    print(a)
    c = []
    answer = []
    
    for i in range(len(a)):
        c.append(a[i])

        if len(a) == 1:
         answer += c   
        
        elif a[i][0] != a[i+1][0] and i != len(a) - 2:
            c.sort(key=lambda x: int(x[1]), reverse=True)
            answer += c
            c = []

        elif a[i][0] != a[i+1][0] and i == len(a) - 2:
            c.sort(key=lambda x: int(x[1]), reverse=True)
            answer += c
            c = []
            c.append(a[i+1])
            answer += c
            break

        elif a[i][0] == a[i+1][0] and i == len(a) - 2:
            c.append(a[i+1])
            c.sort(key=lambda x: int(x[1]), reverse=True)
            answer += c
            break

    print(answer)
    for i in range(len(answer)):
        print(answer[i][2])
        
        
if __name__ == '__main__':

    main()

    


def main():

    N = int(input())
    if 0 > N or N > 100:
        print("input N error")
        exit()
        
    a = []
    for i in range(N):
        b = input().split()
        if len(b[0]) > 10 or len(b[0]) < 1:
            print("input S error")
            exit()

        if int(b[1]) < 0 or int(b[1]) > 100:
            print("input P error")
            exit()

        b.append(i + 1)
        a.append(b)
        
    a.sort()
    c = []
    answer = []
    
    for i in range(len(a) - 1):
        c.append(a[i])

        if i == len(a) - 2:
            elif a[i][0] != a[i+1][0]:
                c.sort(key=lambda x: int(x[1]), reverse=True)
                answer += c
                answer.append(a[i+1])

            else:
                c.append(a[i+1])
                c.sort(key=lambda x: int(x[1]), reverse=True)
                answer += c
                
        elif a[i][0] != a[i+1][0]:
            c.sort(key=lambda x: int(x[1]), reverse=True)
            answer += c
            c = []

            
    for i in range(len(answer)):
        print(answer[i][2])
        
        
if __name__ == '__main__':

    main()

    


def main():

    apple, apple_piece = (int(val) for val in input().split())

    apple_piece += apple * 3
    apple_pie = int(apple_piece / 2)

    print(apple_pie)

if __name__ == '__main__':

    main()


Verdicts: Runtime Error

Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
A, P = map(int, input().split())
print((int((3*A)+P)/2))


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


Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
A, B = map(int, input().split())
kakera = A + B
print(int(kakera/3))

A, B = map(int, input().split())
kakera = A*3 + B
print(int(kakera/3))

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

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
N = int(input())

my_list = []

for i in range(N):
    sp = input().split()
    sp[1] = int(sp[1])
    sp.insert(0, i+1)
    
    my_list.append(sp)
    
my_list.sort(key = lambda x: x[2], reverse=True)
my_list.sort(key = lambda x: x[1])

for i in my_list:
    print(i[0])

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

P = P + A*3

apple_pie = 0

while  P>1:
    
    apple_pie = apple_pie + 1
    P = P - 2
    
print(apple_pie)

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
n = int(input())
book=[]
for i in range(n):
    a,b=input().split()
    temp=[a,int(b),i+1]
    book.append(temp)

book.sort(key=lambda x:x[0])
book.sort(key=lambda x:x[1])

for j in range[len(book)]:
    print(book[j][3])

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

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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
A, P = map(int, input().split())

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

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

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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
n = int(input())
a = []
for i in range(n):
    s, p = input().split()
    p = int(p)
    a.append((s, -int(p), i))
a.sort()

for _, _, i in a:
    print(i + 1)

n = int(input())
a = []
for i in range(n):
    s, p = input().split()
    a.append((s, -int(p), i))
a.sort()

for _, _, i in a:
    print(i + 1)

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

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

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
goukei = input("数値を入力:").split()
apple = int(goukei[0])
piece = int(goukei[1])

maxpiece = apple * 3 + piece
pie = maxpiece / 2

print(int(pie))

goukei = input().split()
apple = int(goukei[0])
piece = int(goukei[1])

maxpiece = apple * 3 + piece
pie = maxpiece / 2

print(int(pie))

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
n = int(input())
l = []
for i in range(n):
    s, p = input().split()
    l.appen([s, -int(p), i + 1])

l.sort()
for i in l:
    print(i[2])

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

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


Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
A,P=map(int,input().split())
ap=A*3+P
print(ap//P)

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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
a,p = map(int, input().split())

cnt = a * 3

print(int(cnt/2))

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

cnt = a * 3

print(int(cnt/p))

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

# a,p = map(int, "1 3".split())


cnt = a * 3 + p

print(int(cnt/2))

Verdicts: Wrong Answer

Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
A, P = map(int, input())
print((A*3+P)//2)

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


Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
def main(a,p):
  b=(a*3+p)/3
  return b

s = input().split()
t=int(s[0])*3+int(s[1])
print(t/3)

s = input().split()
t=int(s[0])*3+int(s[1])
print(t//3)

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

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
A,P=map(int,input().split())
print(((A*3)//2 + b//2) + (((A**3)%2 + b%2)//2))

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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
A,P = map(int,input().split())

if ( A * 3 + P ) % 2 == 0:
  print(( A * 3 + P ) / 2 )
else:
  print( int(( A * 3 + P - 1) / 2 ))

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


for i in range(10**111111):
  a =0

if ( A * 3 + P ) % 2 == 0:
  print(int( ( A * 3 + P ) / 2 ))
else:
  print( int(( A * 3 + P - 1) / 2 ))

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


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


Verdicts: Wrong Answer

Time Limit Exceeded

Accepted
Problem: 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.

Submission attempts (in order):
N = int(input())
rest = {}
cities = []
for i in range(N):
    k,s = input().split()
    if k not in rest:
        rest[k] = []
        cities.append(k)
    rest[k].append([int(s),i+1])
print(sorted(rest))
cities = cities.sort()
for k in cities:
    rest[k].sort(reverse = True)
    for i in rest[k]:
        print(i[1])

N = int(input())
rest = {}
cities = []
for i in range(N):
    k,s = input().split()
    if k not in rest:
        rest[k] = []
        cities.append(k)
    rest[k].append([int(s),i+1])
print(sorted(rest))
cities.sort()
for k in cities:
    rest[k].sort(reverse = True)
    for i in rest[k]:
        print(i[1])

N = int(input())
rest = {}
cities = []
for i in range(N):
    k,s = input().split()
    if k not in rest:
        rest[k] = []
        cities.append(k)
    rest[k].append([int(s),i+1])
print(sorted(rest))
cities.sort()
for k in cities:
    rest[k].sort(reverse = True)
    for i in rest[k]:
        print(i[1])

N = int(input())
rest = {}
cities = []
for i in range(N):
    k,s = input().split()
    if k not in rest:
        rest[k] = []
        cities.append(k)
    rest[k].append([int(s),i+1])
cities.sort()
for k in cities:
    rest[k].sort(reverse = True)
    for i in rest[k]:
        print(i[1])

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

Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
a,p = map(int,input().split())
print(int(a*3+p)/2)


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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
A,P=map(int,input().split())

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

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

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
#! /usr/bin/env python3
# -*- coding: utf-8 -*-
N, M = [int(x) for x in input().split()]

S =[]
for j in range (M):
    a = [x for x in input().split()]
    k = a[0]
    s = [int(x) for x in a[1:]]
    S.append(s)
P = [int(x) for x in input().split()]
ans = 0
for i in range (2**N):
    n = format(i,'b').zfill(N)
    
    count = 0
    for j in range (M):
        count2 = 0
        for k in range (len(S[j])):
            count2 += int(n[S[j][k]-1])
        if count2 %2 == P[j]:
            count += 1
    if count == M:
        ans += 1

print(ans)
        



 
    






#! /usr/bin/env python3
# -*- coding: utf-8 -*-

a = input()
b = a.split()
c,d =b
A=int(c)
P = int(d)

e = 3*A+P

answer = e//2

print(answer)

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
A, P = map(int, input().split())

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


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


Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
import sys
input = sys.stdin.readline
A=int(input())
P=int(input())
if A%2==0:
  A=A*3/2
  print(A+P)
else:
  A=(A*3+P)/2
  print(A)

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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
a,p=map(int,input().split())
x=a+p
print(x//2)

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
a,p = map(int, input().split())
print((a*3 + p)%2)


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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
 a,b=map(int,input().split())
print((3a+b)//2)


 a,b=map(int,input())
print((3a+b)//2)

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


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


 a,b=map(int,input())
print((3*a+b)//2)


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


Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
A,P=[int(i) for input().split()]
print((A//3+P)//2)

A,P=[int(i) for i in input().split()]
print((A//3+P)//2)

A,P=[int(i) for i in input().split()]
print((A*3+P)//2)

Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
A, P = input().split()
P += A*3
print(P//2)

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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
A, P = map(int, input().input())
print((A * 3 + P)//2)

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


Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
a,b=map(int,input().split())
c=a*3
d=c+b
e=d//2
print("e")


a,b=map(int,input().split())
c=a*3
d=c+b
e=d//2
print(e)


Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
import sys;input=sys.stdin.readline
from bisect import*

n,q=map(int,input().split())
event=[]
stopped=set([-1])

def doevent(l):
    global stopped
    if l[1]==1:
        if stopped=={-1}:
            stopped=set()
        stopped.add(l[2])
    elif l[1]==-1:
        if l[2] in stopped:
            stopped.remove(l[2])
        if len(stopped)==0:
            stopped={-1}
            
for i in range(n):
    s,t,x=map(int,input().split())
    event.append((s-x,1,x))
    event.append((t-x,-1,x))
event.append((-float("inf"),"x","x"))
event.append((float("inf"),"x","x"))
event.sort(key=lambda x:x[0])
eventtime=[i[0]for i in event]
#print(eventtime)
query=[bisect_right(eventtime,int(input()))-1 for i in range(q)]+[float("inf")]
#print(query)
c=0
#print(event)
for i in range(2*n+1):
    doevent(event[i])
    while i==query[c]:
        print(min(stopped))
        c+=1


import sys;input=sys.stdin.readline
from bisect import*

n,q=map(int,input().split())
event=[]
stopped={-1}

def doevent(l):
    global stopped
    if l[1]==1:
        if stopped=={-1}:
            stopped=set()
        stopped.add(l[2])
    elif l[1]==-1:
        stopped.remove(l[2])
        if len(stopped)==0:
            stopped={-1}
            
for i in range(n):
    s,t,x=map(int,input().split())
    event.append((s-x,1,x))
    event.append((t-x,-1,x))
event.append((-float("inf"),"x","x"))
event.append((float("inf"),"x","x"))
event.sort(key=lambda x:x[0])
eventtime=[i[0]for i in event]
#print(eventtime)
query=[bisect_right(eventtime,int(input()))-1 for i in range(q)]
#print(query)
c=0
#print(event)
for i in range(2*n):
    doevent(event[i])
    while i==query[c]:
        print(min(stopped))
        c+=1
        if c==q:
            break
for i in range(query.count(2*n)):
    print(-1)


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

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
import math
a,p=map(int.input().split())
p=p+a*3
print(math.floor(p/3))

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

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

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

Verdicts: Runtime Error

Wrong Answer

Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
a,p = map(int,input().split()
print(int((a*3+p)/2))

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

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

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
A,B=map(int,input().split())
print((3*A+B)//3)

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
a, p = map(int, input().split())
print((a**3 + p) // 2)

#!/usr/bin/env python3
a, p = map(int, input().split())
print((a*3+p)//2)

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
a, b=map(int,input().split()) 
print((a*3+b)/2)

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
A, P = map(int, input(' '))
print((3*A+P)//2)

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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
a,b = map(int,input().split())
print((a*3+p)//2)

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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
a, p = map(int, input().split())
print(a * 3 + p // 2)


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


Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
N , K = map(int,input().split())
D = list(map(int,input().split()))

maxValue = 0

for i in range(min(N,K)+1):
    for j in range(min(N,K)-i+1):
        left = D[:i]
        right = D[N-j:]
        merge = (left + right + [0]).sort()

        index = 0

        for k in range(K-i-j):
            if (merge[0] < 0):
                index += 1
            else:
                break

        val = sum(merge[index:])
        if(maxValue < val):
            maxValue = val

print(maxValue)

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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
A, P = map(int, input().split())
print((2*A+P)//2)

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
x,y = map(int,input().split())
print((x*2+y)//2)

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
apple, peace = map(int, input().split())
print(apple * 3 + peace // 2)

apple, peace = map(int, input().split())
print(apple * 3 + peace //3)

apple, peace = map(int, input().split())
print((apple * 3 + peace) // 2)

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
print(0)

# coding: utf-8
# Your code here!

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

# print(A)
# print(P)

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

Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):

A = int(input())

P = int(input())

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


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

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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
A, P = map(int, input())

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

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

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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
a,p = map(int, input.split())
print((a*3+p) // 2)


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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):

A = int(input())
P = int(input())

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

print(ans)


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

Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
n,m=map(int,input().split())

lamp=[]
switches=[]
temp=[]

for i in range(m):
    temp=list(map(int,input().split()))
    lamp.append(temp.pop(0))
    switches.append(temp)
    temp=[]

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

bit_list=[]

for i in range(2**(n)):
    bit_list.append(bin(i)[2:].zfill(n))

ans = 0

for b in bit_list:
    flag = 0
    sum  = 0
    for s,p in zip(switches,modul):
        for k in range(len(s)):
            sum=sum+int(b[s[k]-1])
        if sum%2 != p:
            flag = 1
            break
    if flag == 0:
        ans=ans+1

print(ans)


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

p1=p+(3*a)

print(p1//2)


Verdicts: Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
a,p=map(int,inputy().split())
print((3*a+p)//2)


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


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


Verdicts: Runtime Error

Runtime Error

Accepted
Problem: 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.

Submission attempts (in order):
A, P = map(int, input().split())

piece = A * 3
pie = piece // 2
print(pie)


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

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




Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
A,P=map(int,input().split())
print(int((A*3+P)/3))

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


Verdicts: Wrong Answer

Accepted
Problem: 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.

Submission attempts (in order):
a,p=map(int,input().split())
print((3*a)//2)

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

Verdicts: Wrong Answer

Accepted