Buggy python submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-
a = int(input())

for i in range(a):
  lis = list(map(int, input().split()))
  judge = True
  if (lis[i] % 2 == 0):
    if (lis[i] % 3 != 0) and (lis[i] % 5 != 0):
      judge = False
# 出力
if judge:
  print("APPROVED")
else:
  print("DENIED")

Fixed submission:
# -*- coding: utf-8 -*-
a = int(input())
lis = list(map(int, input().split()))
for i in range(a):
  judge = True
  if (lis[i] % 2 == 0):
    if (lis[i] % 3 != 0) and (lis[i] % 5 != 0):
      judge = False
      break
# 出力
if judge:
  print("APPROVED")
else:
  print("DENIED")

Buggy python submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-
a = int(input())
for i in range(a):
  b = int(input())
  judge = True
  if (b % 2 == 0):
    if (b % 3 != 0) and (b % 5 != 0):
      judge = False
# 出力
if judge:
  print("APPROVED")
else:
  print("DENIED")

Fixed submission:
# -*- coding: utf-8 -*-
a = int(input())
lis = list(map(int, input().split()))
for i in range(a):
  judge = True
  if (lis[i] % 2 == 0):
    if (lis[i] % 3 != 0) and (lis[i] % 5 != 0):
      judge = False
      break
# 出力
if judge:
  print("APPROVED")
else:
  print("DENIED")

Buggy python submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-
a = int(input())
judge = True
for i in range(a):
  b = int(input())
  if (b % 2 == 0):
    if (b % 3 != 0) and (b % 5 != 0):
      judge = False
# 出力
if judge:
  print("APPROVED")
else:
  print("DENIED")

Fixed submission:
# -*- coding: utf-8 -*-
a = int(input())
lis = list(map(int, input().split()))
for i in range(a):
  judge = True
  if (lis[i] % 2 == 0):
    if (lis[i] % 3 != 0) and (lis[i] % 5 != 0):
      judge = False
      break
# 出力
if judge:
  print("APPROVED")
else:
  print("DENIED")

Buggy python submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-
a = int(input())
judge = True
for i in range(a):
  b = int(input())
  if (b % 2 == 0)
    if (b % 3 != 0) and (b % 5 != 0):
      judge = False
# 出力
if judge:
  print("APPROVED")
else:
  print("DENIED")

Fixed submission:
# -*- coding: utf-8 -*-
a = int(input())
lis = list(map(int, input().split()))
for i in range(a):
  judge = True
  if (lis[i] % 2 == 0):
    if (lis[i] % 3 != 0) and (lis[i] % 5 != 0):
      judge = False
      break
# 出力
if judge:
  print("APPROVED")
else:
  print("DENIED")

Buggy python submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-
a = int(input())
judge = True
for i in range(a):
  b = int(input())
  if (b % 2 == 0)
    if (b % 3 != 0) or (b % 5 != 0):
      judge = False
# 出力
if judge:
  print("APPROVED")
else:
  print("DENIED")

Fixed submission:
# -*- coding: utf-8 -*-
a = int(input())
lis = list(map(int, input().split()))
for i in range(a):
  judge = True
  if (lis[i] % 2 == 0):
    if (lis[i] % 3 != 0) and (lis[i] % 5 != 0):
      judge = False
      break
# 出力
if judge:
  print("APPROVED")
else:
  print("DENIED")

Buggy python submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-
a = int(input())
judge = True
for i in range(a):
  b = int(input())
  if (b % 2 == 0) and (b % 3 != 0) and (b % 5 != 0):
    judge = False
# 出力
if judge:
  print("APPROVED")
else:
  print("DENIED")

Fixed submission:
# -*- coding: utf-8 -*-
a = int(input())
lis = list(map(int, input().split()))
for i in range(a):
  judge = True
  if (lis[i] % 2 == 0):
    if (lis[i] % 3 != 0) and (lis[i] % 5 != 0):
      judge = False
      break
# 出力
if judge:
  print("APPROVED")
else:
  print("DENIED")

Buggy python submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-
a = int(input())
judge = True
for i in range(a):
  b = int(input())
  if (b % 2 == 0) and ((b % 3 != 0) or (b % 5 != 0)):
    judge = False
# 出力
if judge:
  print("APPROVED")
else:
  print("DENIED")

Fixed submission:
# -*- coding: utf-8 -*-
a = int(input())
lis = list(map(int, input().split()))
for i in range(a):
  judge = True
  if (lis[i] % 2 == 0):
    if (lis[i] % 3 != 0) and (lis[i] % 5 != 0):
      judge = False
      break
# 出力
if judge:
  print("APPROVED")
else:
  print("DENIED")

Buggy python submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-
a = int(input())
judge = True
for i in range(a):
  b = int(input())
  if (b % 2 == 0) and ((b % 3 == 0) or (b % 5 == 0)):
    judge = False
# 出力
if judge:
  print("APPROVED")
else:
  print("DENIED")

Fixed submission:
# -*- coding: utf-8 -*-
a = int(input())
lis = list(map(int, input().split()))
for i in range(a):
  judge = True
  if (lis[i] % 2 == 0):
    if (lis[i] % 3 != 0) and (lis[i] % 5 != 0):
      judge = False
      break
# 出力
if judge:
  print("APPROVED")
else:
  print("DENIED")

Buggy python submission (verdict: Runtime Error):
# -*- coding: utf-8 -*-
a = int(input())
judge = True
for i in range(a):
  b = int(input())
  if (b % 2 == 0) & ((b % 3 == 0) or (b % 5 == 0)):
    judge = False
# 出力
if judge:
  print("APPROVED")
else:
  print("DENIED")

Fixed submission:
# -*- coding: utf-8 -*-
a = int(input())
lis = list(map(int, input().split()))
for i in range(a):
  judge = True
  if (lis[i] % 2 == 0):
    if (lis[i] % 3 != 0) and (lis[i] % 5 != 0):
      judge = False
      break
# 出力
if judge:
  print("APPROVED")
else:
  print("DENIED")