TnT/Multi_CodeNet4Repair huggingface dataset:
Problem: Takahashi and Aoki will take N exams numbered 1 to N. They have decided to compete in these exams. The winner will be determined as follows:    * For each exam i, Takahashi decides its _importance_ c_i, which must be an integer between l_i and u_i (inclusive).    * Let A be \sum_{i=1}^{N} c_i \times (Takahashi's score on Exam i), and B be \sum_{i=1}^{N} c_i \times (Aoki's score on Exam i). Takahashi wins if A \geq B, and Aoki wins if A < B.  Takahashi knows that Aoki will score b_i on Exam i, with his supernatural power.  Takahashi himself, on the other hand, will score 0 on all the exams without studying more. For each hour of study, he can increase his score on some exam by 1. (He can only study for an integer number of hours.) However, **he cannot score more than X on an exam**, since the perfect score for all the exams is X.  Print the minimum number of study hours required for Takahashi to win.

Submission attempts (in order):
N,X=map(int,input().split())
above=[0]*N
under=[0]*N
now=0
data=[0]*N
for i in range(N):
    b,l,u=map(int,input().split())
    above[i]=(b*l+(X-b)*u)
    data[i]=(i,b,l,u)
    under[i]=(i,l*b)
    
    now-=l*b
above.sort(key=lambda x:x[1],reverse=True)
idx=0
used=set()
ans=0
while above[idx][1]+now<0:
    now+=above[idx][1]
    used|={above[idx][0]}
    idx+=1
    ans+=X
M=float('inf')
now*=-1
ansM=i
nowM=now
for i in range(N):
    if i in used:
        continue
    b,l,u=data[i]
    M0=(now+l-1)//l
    if M0>b:
        now0=now-l*b
        M0=b+(now0+u-1)//u
        if M0<=X and M0<M:
            M=M0
            ansM=i
            nowM=now0-(M0-b)*u
    elif M0<M:
        M=M0
        ansM=i
        nowM=now-M0*l
ans+=M
nowM*=-1
check=[data[i] for i in used|{ansM}]
check.sort(key=lambda x:x[2])
idx=0
while idx<len(check):
    if nowM-check[idx][2]>=0:
        nowM-=check[idx][2]
        ans-=1
    else:
        idx+=1
print(ans)

N,X=map(int,input().split())
data=[0]*N
A=[0]*N
zero=0
for i in range(N):
    b,l,u=map(int,input().split())
    zero-=l*b
    data[i]=(b,l,u)
    A[i]=(i,(X-b)*u+b*l)
A.sort(key=lambda x:x[1],reverse=True)
S=[0]*N
idx=[0]*N
for i,a in enumerate(A):
    S[i]=S[i-1]+a[1]
    idx[a[0]]=i
def check(k):
    q=k//X
    r=k-q*X
    for i in range(N):
        b,l,u=data[i]
        if q==0:
            now=zero
        elif idx[i]<q:
            now=zero+S[q]-A[idx[i]][1]
        else:
            now=zero+S[q-1]
        if r<=b:
            now+=r*l
        else:
            now+=(r-b)*u+b*l
        if now>=0:
            return True
    return False
Mincan=N*X
Maxcant=-1
c=(1,2)
while True:
    if Maxcant+1==Mincan:
        ans=Mincan
        break
    x=N*X*c[0]//c[1]
    if check(x):
        if Mincan>x:
            Mincan=x
            c=(c[0]*2-1,c[1]*2)
    else:
        if Maxcant<x:
            Maxcant=x
            c=(c[0]*2+1,c[1]*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())
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())

apple_cut = A * 3

apple_pie = (apple_cut + P) /2
                 
print(int(apple_pie))

apple,apple_piece = map(int(input(),split())

apple_cut = apple * 3

apple_pie = (apple_cut + apple_piece) /2
                 
print(apple_pie)

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

apple_cut = A * 3

apple_pie = (apple_cut + P) /2
                 
print(apple_pie)

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

apple_cut = A * 3

apple_pie = (apple_cut + P) /2
                 
print(int(apple_pie))

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

apple_cut = A * 3

apple_pie = (apple_cut + P) /2
                 
print(int(apple_pie))

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())
B = A*3
AP  = B+P
Pie =  AP/2
print(Pie)


A,P = map(int,input().split())
B = A*3
AP  = B+P
Pie =  AP//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((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,p= map(int,input().split())
print(a+p//3)



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):
import sys
from heapq import *
input = sys.stdin.readline

def main():
    n, q = map(int, input().split())
    
    key = []
    for i in range(n):
        s, t, x = map(int, input().split())
        l, r = max(0, s-x), max(0, t-x)
        key.append((l, 1, x))
        key.append((r, -1, x))

    key.sort()
    judge = []
    now = set()
    already = dict()
    
    index = 0
    ans = -1
    for i in range(q):
        d = int(input())
        for i in range(index, 2*n):
            s, j, x = key[i]
            if s > d:
                index = i
                break
            if j == 1:
                heappush(judge, x)
                now.add(x)
            else:
                now.remove(x)
                if x in already:
                    already[x] += 1
                else:
                    already[x] = 1
                    
                    
        while judge:
            if judge[0] in already and already[judge[0]] > 0:
                already[judge[0]] -= 1
                heappop(judge)
            else:
                break
        if judge:
            ans = judge[0]
        else:
            ans = -1      
            
        print(ans)

    
if __name__ == "__main__":
    main()




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

k = 3 * a + p
print(k // 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((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,p = map(int,input().split())
print((3＊a+p)//2)

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

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

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

Verdicts: 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())
sum = a*3+p
pi = sum/2
print(pi)


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


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())
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):
print(eval(input().replace(' ','*3-')+'//2'))

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


print(eval('('+input().replace(' ','*3+')+')//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((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):
x = input().split(" ")
a = int(x[0])
b = int(x[1])

r = a * 3 + b

print(r // 3)

x = input().split(" ")
a = int(x[0])
b = int(x[1])

r = (a * 3) + b

print(r // 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())
def crush(A):
    return A * 3

def create_apple_pie(piece):
    return piece // 2

create_apple_pie(crush(a) + p)

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

def crush(A):
    return A * 3

def create_apple_pie(piece):
    return piece // 2

print(create_apple_pie(crush(a) + p))

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('A'))
P = int(input('P'))

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


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

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


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


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())

a *= 3

print((a+b)//2)

a, b = map(int, input().split())
a *= 3
print((a+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):
import sys
_args = sys.argv
_A = _args[1]
_P = _args[2]

if _A > 0 :
    _P=_P+_A*3

_ANS =math.floor(_P/2)

print(_ANS)

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())
pieces=3*A+P
pies=int(pieces/2)


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

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 = 0
P = 0
ans = 0

A = input("りんごの個数を入力してください。")
P = input("りんごの破片の個数を入力してください。")

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

ans = round(ans)

print(ans)



ans = 0


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

ans = round(ans)

print(ans)



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

ans = round(ans)

print(ans)



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

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

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

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 
# Apple Pie

a_p = input()

a = a_p.split(" ")[0]
p = a_p.split(" ")[1]



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

# A 
# Apple Pie

a_p = input()

a = a_p.split(" ")[0]
p = a_p.split(" ")[1]

print(int ((3* int(a) + 1 * int(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())

N = (A*3+P%2)//2+P//2

print(N)


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

N = (A*3+P%2)//2+P//2

print(N)

A = input()
P = input()

N = (A*3+P%2)//2+P//2

print(N)

A, P = (int(i) for i in input().split())
  
N = (A*3+P%2)//2+P//2

print(N)

Verdicts: 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())
 (a*3+p)//2
 

n= int(input())
s = [[input().split()]for i in range(n)]
s1 = sorted(s)
for i in range(n):
    print(s.index(s1[i]))


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,p = map(int,input(). split())
sum = (a*3+3)/2
print(sum)

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

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

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 = input()
P = input()
ans = int((int(A) * 3  + int(P))/2)


print(ans) 

apple = input()
kakera = input()
ans = int((int(apple) * 3  + int(kakera))/2)


print(ans) 

A, P = input().strip().split()

ans = int((int(A) * 3  + int(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):
printf((3A + P)/2)

A, B = map(int, input().split())
C = (3*A+B) / 2
print("{}".format(C))


A, B = map(int, input().split())
print("{}".format((3A+b)/2))

a, p = map(int, input().split())
c = int((3*a+p) / 2)
print("{}".format(c))


Verdicts: Runtime Error

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())

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

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

print(int(((3 * A + P)-((3 * A + P) % 2)) / 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 itertools

n, m = input().split()
N = int(n)
M = int(m)

K = []
for i in range(M):
    K.append(list(map(int, input().strip().split(' '))))

P = list(map(int, input().strip().split(' ')))

SW = {0, 1}
SWlist = list(itertools.product(SW, repeat=N))

result = 0
fflag = False

for i in range(len(SWlist)):
    for j in range(len(K)):
        count = 0
        for k in range(K[j][0]):
            if SWlist[i][k] == 1:
                count += 1
        if count % 2 != P[j]:
            fflag = True
            break
    if not fflag:
        result += 1
    else:
        fflag = False
print(result)


n, m = input().split()
A = int(n)
P = int(m)

N = A * 3 + P
result = N // 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())
num = a*3 // p
print(num)


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

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):
T,O = map(int,input().split())
T *= 3

print((T+O)/2)


T,O = map(int,input().split())
T *= 3

if (T+O) /2 > 0:
  print((T+O)/2)
else:
  print("0")


T,O = map(int,input().split())
T *= 3

if (T+O) /2 > 0:
  print(int((T+O)/2))
else:
  print("0")


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):
#include <stdio.h>

int main(void){
  int a;
  int p;
  
  scanf("%d",a); scanf("%d",a);
  print("%d", (a*3+p)/2);

  return 0;
}

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())

B=P//2

print(A+B)

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

B=P//2

print(A+B)

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

B=A*3


D=B+P
print(D//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):
import sys
A, P = map(int, input().split())
ans = (A + 3*P) // 2

print(ans)

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

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)


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):
n, m = map(int, input().split())
print(int(((n*3)+m)//3))

n, m = map(int, input().split())
print(int(((n*3)+m)//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: 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((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):
# -*- coding: utf-8 -*-
"""
Created on Wed Jun  5 09:53:48 2019

@author: Enya
"""

input_code = input()
A = int(input_code.split()[0])
P = int(input_code.split()[1])

X = A*3 + P
N = 0

if A>3:
    N = A//3

else:
    N = 0
    
print(N)

# -*- coding: utf-8 -*-
"""
Created on Wed Jun  5 09:53:48 2019

@author: Enya
"""

input_code = input()

A = input_code[0]*3 + input_code[1]
N = 0

if A>3:
    N = A//3

else:
    N = 0
    
print(N)
    

# -*- coding: utf-8 -*-
"""
Created on Wed Jun  5 09:53:48 2019

@author: Enya
"""

input_code = input()

A = input_code[0]*3 + input_code[1]
N = 0

if A>3:
    N = A//3
    
    print(N)

else:
    print(0)
    

# -*- coding: utf-8 -*-
"""
Created on Wed Jun  5 09:53:48 2019

@author: Enya
"""

input_code = input()

A = int(input_code[0])*3 + int(input_code[2])
N = 0

if A>3:
    N = A//3

else:
    N = 0
    
print(N)
    

# -*- coding: utf-8 -*-
"""
Created on Wed Jun  5 09:53:48 2019

@author: Enya
"""

input_code = input()
A = int(input_code.split()[0])
P = int(input_code.split()[1])

X = A*3 + P

print(X//2)

Verdicts: Wrong Answer

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)/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 = int(input())
list_shop = []
 
for i in range(n):
  t = []
  a, b = input().split()
  t.append(a)
  t.append(b)
  t.append(str(i + 1))
  list_shop.append(t)
 
check = 0
c = []
 
list_shop = sorted(list_shop, key=lambda x: x[0])
 
for i in range(len(list_shop) - 1):
  if(list_shop[i][0] == list_shop[i + 1][0]):
    check = 1
  else:
    check = 0
 
  c.append(list(map(int, list_shop[i][1:3])))
  if(check == 1):
    continue
  else:
    c.sort(key=lambda x:x[0], reverse=True)
    for j in c:
      print(int(j[1]))
    c = []
 
if(check == 1):
  c.append(list(map(int, list_shop[n - 1][1:3])))
  c.sort(key=lambda x:x[0], reverse=True)
  for i in c:
    print(i[1])
else:
  print(int(list_shop[n - 1][2]))

n=int(input())
l=[]
for i in range(n):
  s,p=[x for x in input().rstrip().split()]
  l.append([s,int(p),i+1])
l.sort(key=lambda x:x[1],reverse=True)
l.sort(key=lambda x:x[0])

for s,p,i in l:
  print(i) 


l = [int(i) for i in input().split() if i.isdigit()]
print(int((3 * l[0] + l[1]) / 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):
#17:09
n,k = map(int,input().split())
v = list(map(int,input().split()))

can = []
nk = min(n,k)
for a in range(nk+1):
  if a != 0:
    x.append(v[a-1])
  else:
    x = []
  for b in range(nk+1-a):
    if b != 0:
      y.append(v[-b])
    else:
      y = []
    z = x + y
    z.sort()
    r = k - a - b
    tmp = 0
    if r < a+b:
      if z[r] < 0:
        for i in range(r,a+b):
          tmp += z[i]
      else:
        for i in range(a+b):
          if z[i] >= 0:
            tmp += z[i]
    else:
      for i in range(a+b):
        if z[i] >= 0:
          tmp += z[i]
    can.append(tmp)
print(max(can))

#14:16
a,b = map(int,input().split())
print( (3 * a + 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 = int(input())
P = int(input())
print( (A*3+P)//2 )


S = input()
A,P = S.split(' ')
print( (int(A)*3+int(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())
n = 3*a +b
res = int(n/3)
print(res)

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

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((p+3*a)//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,m=map(int,input().split())
s=[list(map(int,input().split()))[1:] for i in range(m)]
p=list(map(int,input().split()))
cnt=0

for i in range(2**n):
    pattern=format(i,"b").zfill(n)
    point=0
    
    for j in range(m):
        swi=0
        for k in s[j]:
            if pattern[k-1]=="1":
              swi +=1
        if swi%2==p[j]:
          point +=1
    if point==m:
      cnt +=1
      
print(cnt)


a,p=int(input().split())
x=3*a+p
if x%2==0:
  print(x/2)
else:
  print((x-1)/2)

n=int(input())
s,p=list(map(int,input().split()))
li=[]
for i in range(0,n):
  li.append((i+1,s[i],p[i]))

new_li=sorted(li,key=lambda x:x[1])
new2_li=sorted(new_li,key=lambda x:x[2])

for j in range(0,n):
  print(new2_li[j][0])

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

a,p=map(int,input().split())
x=3*a+p
print(x//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,b=map(int,input().split())
print(3*(a+b)//2)

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())
print((A*3+P)//2)

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

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((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,p=map(int,input().split())
print((3*a+p)//2))

N = int(input())
B = []
for i in range(N):
    s,p = map(str,input().split())
    tmp = [i+1,s,int(p)]
    B.append(tmp)
B.sort(key=lambda x:x[2],reverse=True)
B.sort(key=lambda x:x[1])
for x in B:
    print(x[0])


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):
N, Q = map(int,input().split())
List_S = [list(map(int,input().split())) for i in range(N)]
List_D = [int(input()) for i in range(Q)]

List_S.sort(key=lambda x:x[2])

for i in range(Q):
    flag = 0
    for j in range(N):
        if (List_S[j][0]-0.5 < (List_D[i] + List_S[j][2])) and ((List_D[i] + List_S[j][2]) < List_S[j][1]-0.5):
            print("{}".format(List_S[j][2]))
            flag = 1
            break
    if flag == 0:
        print("-1")

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

p = A*3 + P
result = int(p / 2)
print("{}".format(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):
N,K = map(int,input().split())
V = list(map(int,input().split()))
ans = 0
R = min(N,K)
for A in range(R+1):
    for B in range(R-A+1):
        s = V[:A]+V[N-B:]
        #print(s)
        s.sort()
        S = sum(s)
        for k in range(min(K-A-B,len(s))):
            if s[k] < 0:
                S -= s[k]
        ans = max(ans,S)
print(ans)

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, p = (int(i) for i in input().split())
print(a*3 // p)

a, p = (int(i) for i in 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())
b=3*a+p
if b%2==0:
  print(b/2)
else:
  print((b-1)/2)


a,p=map(int,input().split())
b=3*a+p
if b%2==0:
  print(b/2)
else:
  print((b-1)/2)

a,p=map(int,input().split())
b=3*a+p
if b%2==0:
  print(b//2)
else:
  print((b-1)//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, b = list(map(int, input().split()))
print((a*3+p)//2)

a, b = list(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+2)//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):
#!/usr/bin/python
# coding: UTF-8
 
n,m = map(int,input().split())
 
s = []
for i in range(m):
    s += [tuple(map(int,input().split())),]
 
p = list(map(int,input().split()))
 
ret = 0
all = [(str(bin(i)))[2:].zfill(n) for i in range(2 ** n)]
all = [[int(i) for i in case] for case in all]
for case in all:
    flag = 0
    for num,i in enumerate(s):
 
        sw = [0 for z in range(n)]
        for k in i[1:]:
            sw[k-1] = 1
 
        if (sum(i*j for i,j in zip(sw,case)) % 2) != p[num]:
            flag = 1
           
    if flag == 0:
        ret += 1
 
print(ret)

#!/usr/bin/python
# coding: UTF-8

a,p = input().split()

a = int(a)
p = int(p)

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 = list(map(int, input().split()))
n = a * 3 + b
c = n % 2
my_result = (n - c) / 2
print(my_result)

a, b = list(map(int, input().split()))
n = a * 3 + b
c = n % 2
my_result = (n - c) / 2
print(int(my_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=int(input().split())

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

a,p=input().split()

print(int((a*3+p)/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 = map(int,input().split())
c = a*3+p
print(c % 2)

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

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())

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

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

P += 3*A
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 = int( x ) for x in input()
print( ( A * 3 + P ) // 2 )


A, P = int( x ) for x in 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, P = map(int, input().split())

a = A*3 + P

if a > 0:
  print(math.floor(a/2))
else:
  print(0)

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

a = A*3 + P

print(math.floor(a/2))

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

a = A*3 + P

if a > 0:
  print(int(a/2))
else:
  print(0)


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(a*3/2)

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(int((a*3+p)/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 + 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):
N, K = map(int, input().split())
d = list(map(int, input().split()))
left = [0]
left_m = []
right = [0]
right_m = []
for i, l, r in zip(range(K), d, d[::-1]):
    left.append(left[i] + l)
    left_m.append(l if l < 0 else 0)
    right.append(right[i] + r)
    right_m.append(r if r < 0 else 0)
point = 0
for i in range(K):
    for j in range(K - i):
        p = K - i - j
        minus = list(sorted(left_m[:i] + right_m[:j]))
        point = max(point, left[i] + right[j] - sum(minus[:p]))
print(point)


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(int((A*3*2+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):
from collections import defaultdict

N = int(input())
S = [0] * N
P = [0] * N

city_point = {}

for i in range(N):
    inp = input().split()
    S[i] = inp[0]
    P[i] = inp[1]
    city_point[i] = {'city': S[i], 'point': int(P[i])}
    
sorted_list = sorted(city_point.items(), key=lambda x: (x[1]['city'], x[1]['point']))

for item in sorted_list:
    print(item[0] + 1)


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

apple_slices = A * 3 + P

print(apple_slices // 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):
import heapq
import sys
sys.setrecursionlimit(10 ** 7)

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

event=[]
for _ in range(n):
    s,t,x=map(int,input().split())
    event.append([s-x,1,x])
    event.append([t-x,-1,x])

for i in range(q):
    event.append([int(input()),2,i])
event.sort()

ans=[0]*q

stop=set()
hq=[]
for e in event:
    t,op,x=map(lambda x:x,e)
    if op==1:
        heapq.heappush(hq,x)
        stop.add(x)
    elif op==-1:
        stop.remove(x)

    else:
        while hq and hq[0] not in stop:
            heapq.heappop(hq) 
        ans[x]=hq[0] if hq else -1
    
for x in ans:
    print(x)

import sys

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():
    N = int(input())
    restaurants = []
    for i in range(N):
        si, pi = input().split()
        restaurants.append([i+1, si, int(pi)])
    cities = sorted(set([restaurant[1] for restaurant in restaurants]))

    for city in cities:
        same_cities = []
        for restaurant in restaurants:
            if restaurant[1] == city:
                same_cities.append(restaurant)
        sorted_restaurants = sorted(same_cities, key=lambda restaurant: restaurant[2], reverse=True)
        [print(restaurant[0]) for restaurant in sorted_restaurants]


if __name__ == '__main__':
    main()



def main():
    A, P = [ int(x) for x in input().split() ]
    n = (A * 3 + P) / 2
    print(int(n))

if __name__ == '__main__':
    main()


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):
#1107
A, P = map(int, input().split())
print((A*3+P)/2)


from numpy import*
n, m = map(int, input().split())
l = []
for i in range(m):
    *a,=map(int,input().split())
    l.append(a[1:])
*p,=map(int,input().split())
ans = 0
for t in range(2**n):
    for s in range(n):
        tmp = array([t >> s & 1])
    for i in l:
        if p == sum(tmp[array(i)-1])%2:
            ans += 1
print(ans)

#1107
import math
A, P = map(int, input().split())
print(math.floor((A*3+P)/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())
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):
a,p = map(int,input().split())
print((a+3*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):
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):
a = int(input().split()[0])
p = int(input().split()[1])

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

a = input().split()
an = int(a[0])
p = int(a[1])

s = an * 3 + p
print(s // 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())
dic = {}
for x in range(n):
  dic[x+1] = input().split()
ls = sorted(dic.items(), key=lambda x:x[1][0])

for y in range(1,n-1):
  
  if ls[y][1][0] == ls[y+1][1][0]:
    
    if ls[y][1][1] < ls[y+1][1][1]:
      
      ls[y+1],ls[y] = ls[y],ls[y+1]
    
    
for b in range(len(ls)):
  print(ls[b][0])


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,ki=map(int,input().split())
v=list(map(int,input().split()))

m=min(n,ki)
ans=0

for i in range(m+1):
    for j in range(i+1):
        q=[]
        tmp=0
        for k in range(j):
            if len(v)>0:
                q.append(v[k])
        for kz in range(i-j):
            if len(v)>0:
                q.append(v[n-1-kz])
        tmp=sum(q)
        q.sort()
        for l in range(ki-i):
            if l<len(q) and q[l]<0:
                tmp-=q[l]
        ans=max(ans,tmp)
        
print(ans)

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: Runtime Error

Accepted