output_description: Print the maximum number of apple pies we can make with what we have.
  
  * * *
input_description: Input is given from Standard Input in the following format:
  
      
      
      A P
attempt: import sys
  
  input = sys.stdin.readline
  inf = float("inf")
  mod = 10**9 + 7
  
  
  def INT_(n):
      return int(n) - 1
  
  
  def MI():
      return map(int, input().split())
  
  
  def MF():
      return map(float, input().split())
  
  
  def MI_():
      return map(INT_, input().split())
  
  
  def LI():
      return list(MI())
  
  
  def LI_():
      return [int(x) - 1 for x in input().split()]
  
  
  def LF():
      return list(MF())
  
  
  def LIN(n: int):
      return [input() for _ in range(n)]
  
  
  def LLIN(n: int):
      return [LI() for _ in range(n)]
  
  
  def LLIN_(n: int):
      return [LI_() for _ in range(n)]
  
  
  def LLI():
      return [list(map(int, l.split())) for l in input()]
  
  
  def I():
      return int(input())
  
  
  def F():
      return float(input())
  
  
  def ST():
      return input().replace("\n", "")
  
  
  def main():
      A, P = MI()
      print((A * 3 + P) // 2)
  
  
  if __name__ == "__main__":
      main()
  
problem_description: Statement
  
  We have A apples and P pieces of apple.
  
  We can cut an apple into three pieces of apple, and make one apple pie by
  simmering two pieces of apple in a pan.
  
  Find the maximum number of apple pies we can make with what we have now.
samples: [{"input": "1 3", "output": "3\n    \n\nWe can first make one apple pie by simmering two of the three pieces of apple.\nThen, we can make two more by simmering the remaining piece and three more\npieces obtained by cutting the whole apple.\n\n* * *"}, {"input": "0 1", "output": "0\n    \n\nWe cannot make an apple pie in this case, unfortunately.\n\n* * *"}, {"input": "32 21", "output": "58"}]