output_description: If the immigrant should be allowed entry according to the regulation, print
  `APPROVED`; otherwise, print `DENIED`.
  
  * * *
input_description: Input is given from Standard Input in the following format:
  
      
      
      N
      A_1 A_2 \dots A_N
attempt: lines = []
  for i in range(2):
      inp = input()
      lines.append(inp)
  searchList = []
  for i in range(int(lines[0])):
      split = lines[1].split()
      if int(split[i]) % 2 == 0:
          searchList.append(int(split[i]))
  out = "APPROVED"
  for s in searchList:
      if s % 3 != 0 and s % 5 != 0:
          out = "DENIED"
          print(out)
          break
  if out == "APPROVED":
      print(out)
  
problem_description: Statement
  
  You are an immigration officer in the Kingdom of AtCoder. The document carried
  by an immigrant has some number of integers written on it, and you need to
  check whether they meet certain criteria.
  
  According to the regulation, the immigrant should be allowed entry to the
  kingdom if and only if the following condition is satisfied:
  
    * All even numbers written on the document are divisible by 3 or 5.
  
  If the immigrant should be allowed entry according to the regulation, output
  `APPROVED`; otherwise, print `DENIED`.
samples: [{"input": "5\n    6 7 9 10 31", "output": "APPROVED\n    \n\nThe even numbers written on the document are 6 and 10.\n\nAll of them are divisible by 3 or 5, so the immigrant should be allowed entry.\n\n* * *"}, {"input": "3\n    28 27 24", "output": "DENIED\n    \n\n28 violates the condition, so the immigrant should not be allowed entry."}]