import sys

input()
numbers = map(int, input().split())
evens = [number for number in numbers if number % 2 == 0]

if len(evens) == 0:
    print('APPROVED')
    sys.exit()
    
for even in evens:
    if even % 3 != 0 and even % 5 != 0:
        print('DENIED')
        sys.exit()

print('APPROVED') import sys sys input() input numbers = map(int, input().split()) numbers map(int, input().split()) map int input().split() ().split () input split number for number in numbers if number % 2 == 0 for number in numbers if number % 2 == 0 number numbers number % 2 == 0 number % 2 number 2 0 if number % 2 == 0 number evens = [number for number in numbers if number % 2 == 0] evens [number for number in numbers if number % 2 == 0] if len(evens) == 0:
    print('APPROVED')
    sys.exit()
     len(evens) == 0 len(evens) len evens 0 print('APPROVED') print 'APPROVED' sys.exit() sys.exit sys exit for even in evens:
    if even % 3 != 0 and even % 5 != 0:
        print('DENIED')
        sys.exit() even evens if even % 3 != 0 and even % 5 != 0:
        print('DENIED')
        sys.exit() even % 3 != 0 and even % 5 != 0 even % 3 != 0 even % 3 even 3 0 even % 5 != 0 even % 5 even 5 0 print('DENIED') print 'DENIED' sys.exit() sys.exit sys exit print('APPROVED') print 'APPROVED' evens = [number for number in numbers if number % 2 == 0] [number for number in numbers if number % 2 == 0] evens numbers = map(int, input().split()) map(int, input().split()) numbers
import sys

input()
numbers = map(int, input().split())
evens = [number for number in numbers if number % 2 == 0]

if len(evens) == 0:
    print('APPROVED')
    sys.exit()
    
for even in evens:
    if even % 3 != 0 and even % 5 != 0:
        print('DENIED')
        sys.exit()

print('APPROVED')
