import java.util.Scanner;
//import java.util.Arrays;
public class Main{
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		//int[] a = new int[n];
		boolean flg = true;
		for(int i=0; i<n; i++){
			//a[i] = sc.nextInt();
			int a = sc.nextInt();
			if(a%2 == 0){
				if(!(a%3==0 || a%5==0)){
					flg = false;
					
				}
			}
		}
		System.out.println(flg ? "APPROVED" : "DENIED");
	}
} import java.util.Scanner; Scanner java.util public class Main{
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		//int[] a = new int[n];
		boolean flg = true;
		for(int i=0; i<n; i++){
			//a[i] = sc.nextInt();
			int a = sc.nextInt();
			if(a%2 == 0){
				if(!(a%3==0 || a%5==0)){
					flg = false;
					
				}
			}
		}
		System.out.println(flg ? "APPROVED" : "DENIED");
	}
} Main public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		//int[] a = new int[n];
		boolean flg = true;
		for(int i=0; i<n; i++){
			//a[i] = sc.nextInt();
			int a = sc.nextInt();
			if(a%2 == 0){
				if(!(a%3==0 || a%5==0)){
					flg = false;
					
				}
			}
		}
		System.out.println(flg ? "APPROVED" : "DENIED");
	} main {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		//int[] a = new int[n];
		boolean flg = true;
		for(int i=0; i<n; i++){
			//a[i] = sc.nextInt();
			int a = sc.nextInt();
			if(a%2 == 0){
				if(!(a%3==0 || a%5==0)){
					flg = false;
					
				}
			}
		}
		System.out.println(flg ? "APPROVED" : "DENIED");
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc boolean flg = true; flg true for(int i=0; i<n; i++){
			//a[i] = sc.nextInt();
			int a = sc.nextInt();
			if(a%2 == 0){
				if(!(a%3==0 || a%5==0)){
					flg = false;
					
				}
			}
		} int i=0; int i=0; i 0 i<n i n i++ i++ i {
			//a[i] = sc.nextInt();
			int a = sc.nextInt();
			if(a%2 == 0){
				if(!(a%3==0 || a%5==0)){
					flg = false;
					
				}
			}
		} {
			//a[i] = sc.nextInt();
			int a = sc.nextInt();
			if(a%2 == 0){
				if(!(a%3==0 || a%5==0)){
					flg = false;
					
				}
			}
		} int a = sc.nextInt(); a sc.nextInt() sc.nextInt sc if(a%2 == 0){
				if(!(a%3==0 || a%5==0)){
					flg = false;
					
				}
			} a%2 == 0 a%2 a 2 0 {
				if(!(a%3==0 || a%5==0)){
					flg = false;
					
				}
			} if(!(a%3==0 || a%5==0)){
					flg = false;
					
				} !(a%3==0 || a%5==0) (a%3==0 || a%5==0) a%3==0 a%3 a 3 0 a%5==0 a%5 a 5 0 {
					flg = false;
					
				} flg = false flg false System.out.println(flg ? "APPROVED" : "DENIED") System.out.println System.out System System.out flg ? "APPROVED" : "DENIED" flg "APPROVED" "DENIED" String[] args args public class Main{
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		//int[] a = new int[n];
		boolean flg = true;
		for(int i=0; i<n; i++){
			//a[i] = sc.nextInt();
			int a = sc.nextInt();
			if(a%2 == 0){
				if(!(a%3==0 || a%5==0)){
					flg = false;
					
				}
			}
		}
		System.out.println(flg ? "APPROVED" : "DENIED");
	}
} public class Main{
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		//int[] a = new int[n];
		boolean flg = true;
		for(int i=0; i<n; i++){
			//a[i] = sc.nextInt();
			int a = sc.nextInt();
			if(a%2 == 0){
				if(!(a%3==0 || a%5==0)){
					flg = false;
					
				}
			}
		}
		System.out.println(flg ? "APPROVED" : "DENIED");
	}
} Main
import java.util.Scanner;
//import java.util.Arrays;
public class Main{
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		//int[] a = new int[n];
		boolean flg = true;
		for(int i=0; i<n; i++){
			//a[i] = sc.nextInt();
			int a = sc.nextInt();
			if(a%2 == 0){
				if(!(a%3==0 || a%5==0)){
					flg = false;
					
				}
			}
		}
		System.out.println(flg ? "APPROVED" : "DENIED");
	}
}
