n = int(input())

nums = list(map(int, input().split()))

result = "APPROVED"
for num in nums:
    if (num % 2 == 0) and not ((num % 3 == 0) or (num % 5 == 0)):
        result = "DENIED"
        break

print(result) n = int(input()) n int(input()) int input() input nums = list(map(int, input().split())) nums list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split result = "APPROVED" result "APPROVED" for num in nums:
    if (num % 2 == 0) and not ((num % 3 == 0) or (num % 5 == 0)):
        result = "DENIED"
        break num nums if (num % 2 == 0) and not ((num % 3 == 0) or (num % 5 == 0)):
        result = "DENIED"
        break (num % 2 == 0) and not ((num % 3 == 0) or (num % 5 == 0)) num % 2 == 0 num % 2 num 2 0 not ((num % 3 == 0) or (num % 5 == 0)) (num % 3 == 0) or (num % 5 == 0) num % 3 == 0 num % 3 num 3 0 num % 5 == 0 num % 5 num 5 0 result = "DENIED" result "DENIED" break print(result) print result nums = list(map(int, input().split())) list(map(int, input().split())) nums result = "APPROVED" "APPROVED" result n = int(input()) int(input()) n result = "DENIED" "DENIED" result
n = int(input())

nums = list(map(int, input().split()))

result = "APPROVED"
for num in nums:
    if (num % 2 == 0) and not ((num % 3 == 0) or (num % 5 == 0)):
        result = "DENIED"
        break

print(result)