N = int(input())
A = list(map(int,input().split()))
B = len([i for i in A if i % 2==0])
count = 0
for i in A:
    if i % 2 !=0:
        continue
    elif i % 3 ==0 or i % 5==0:
        count  +=1
if count == B:
    print('APPROVED')
else:
    print('DENIED') 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 i for i in A if i % 2==0 for i in A if i % 2==0 i A i % 2==0 i % 2 i 2 0 if i % 2==0 i B = len([i for i in A if i % 2==0]) B len([i for i in A if i % 2==0]) len [i for i in A if i % 2==0] count = 0 count 0 for i in A:
    if i % 2 !=0:
        continue
    elif i % 3 ==0 or i % 5==0:
        count  +=1 i A if i % 2 !=0:
        continue
    elif i % 3 ==0 or i % 5==0:
        count  +=1 i % 2 !=0 i % 2 i 2 0 continue elif i % 3 ==0 or i % 5==0:
        count  +=1 i % 3 ==0 or i % 5==0 i % 3 ==0 i % 3 i 3 0 i % 5==0 i % 5 i 5 0 count  +=1 count 1 if count == B:
    print('APPROVED')
else:
    print('DENIED') count == B count B print('APPROVED') print 'APPROVED' print('DENIED') print 'DENIED' count = 0 0 count B = len([i for i in A if i % 2==0]) len([i for i in A if i % 2==0]) B count  +=1 1 count N = int(input()) int(input()) N A = list(map(int,input().split())) list(map(int,input().split())) A
N = int(input())
A = list(map(int,input().split()))
B = len([i for i in A if i % 2==0])
count = 0
for i in A:
    if i % 2 !=0:
        continue
    elif i % 3 ==0 or i % 5==0:
        count  +=1
if count == B:
    print('APPROVED')
else:
    print('DENIED')
