n = int(input())
a = list(map(int, input().split()))
a = [e for e in a if e % 2 == 0 ]
cnt = 0
for i in a:
    if not (i % 3 ==0) and not (i % 5 ==0):
        cnt = 1
        break
if cnt:
    print("DENIED")
else:
    print("APPROVED") n = int(input()) n int(input()) int input() input a = list(map(int, input().split())) a list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split e for e in a if e % 2 == 0 for e in a if e % 2 == 0 e a e % 2 == 0 e % 2 e 2 0 if e % 2 == 0 e a = [e for e in a if e % 2 == 0 ] a [e for e in a if e % 2 == 0 ] cnt = 0 cnt 0 for i in a:
    if not (i % 3 ==0) and not (i % 5 ==0):
        cnt = 1
        break i a if not (i % 3 ==0) and not (i % 5 ==0):
        cnt = 1
        break not (i % 3 ==0) and not (i % 5 ==0) not (i % 3 ==0) i % 3 ==0 i % 3 i 3 0 not (i % 5 ==0) i % 5 ==0 i % 5 i 5 0 cnt = 1 cnt 1 break if cnt:
    print("DENIED")
else:
    print("APPROVED") cnt print("DENIED") print "DENIED" print("APPROVED") print "APPROVED" a = list(map(int, input().split())) list(map(int, input().split())) a cnt = 1 1 cnt a = [e for e in a if e % 2 == 0 ] [e for e in a if e % 2 == 0 ] a cnt = 0 0 cnt n = int(input()) int(input()) n
n = int(input())
a = list(map(int, input().split()))
a = [e for e in a if e % 2 == 0 ]
cnt = 0
for i in a:
    if not (i % 3 ==0) and not (i % 5 ==0):
        cnt = 1
        break
if cnt:
    print("DENIED")
else:
    print("APPROVED")