import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int[] a = new int[n];
		for(int i = 0; i < n; i++) {
			a[i] = sc.nextInt();
		}
		
		boolean  bool = true; 
		for(int i = 0; i < n; i++) {
			int num =a[i];
			if(num % 2 == 0) {
				if(num % 3 != 0 && num % 5 != 0) {
					bool = false;
					break;
				}
			}
		}
		
		if(bool) {
			System.out.println("APPROVED");
		}else {
			System.out.println("DENIED");
		}
		
		sc.close();
	}
} 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];
		for(int i = 0; i < n; i++) {
			a[i] = sc.nextInt();
		}
		
		boolean  bool = true; 
		for(int i = 0; i < n; i++) {
			int num =a[i];
			if(num % 2 == 0) {
				if(num % 3 != 0 && num % 5 != 0) {
					bool = false;
					break;
				}
			}
		}
		
		if(bool) {
			System.out.println("APPROVED");
		}else {
			System.out.println("DENIED");
		}
		
		sc.close();
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int[] a = new int[n];
		for(int i = 0; i < n; i++) {
			a[i] = sc.nextInt();
		}
		
		boolean  bool = true; 
		for(int i = 0; i < n; i++) {
			int num =a[i];
			if(num % 2 == 0) {
				if(num % 3 != 0 && num % 5 != 0) {
					bool = false;
					break;
				}
			}
		}
		
		if(bool) {
			System.out.println("APPROVED");
		}else {
			System.out.println("DENIED");
		}
		
		sc.close();
	} main {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int[] a = new int[n];
		for(int i = 0; i < n; i++) {
			a[i] = sc.nextInt();
		}
		
		boolean  bool = true; 
		for(int i = 0; i < n; i++) {
			int num =a[i];
			if(num % 2 == 0) {
				if(num % 3 != 0 && num % 5 != 0) {
					bool = false;
					break;
				}
			}
		}
		
		if(bool) {
			System.out.println("APPROVED");
		}else {
			System.out.println("DENIED");
		}
		
		sc.close();
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc int[] a = new int[n]; a new int[n] n for(int i = 0; i < n; i++) {
			a[i] = sc.nextInt();
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			a[i] = sc.nextInt();
		} {
			a[i] = sc.nextInt();
		} a[i] = sc.nextInt() a[i] a i sc.nextInt() sc.nextInt sc boolean  bool = true; bool true for(int i = 0; i < n; i++) {
			int num =a[i];
			if(num % 2 == 0) {
				if(num % 3 != 0 && num % 5 != 0) {
					bool = false;
					break;
				}
			}
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			int num =a[i];
			if(num % 2 == 0) {
				if(num % 3 != 0 && num % 5 != 0) {
					bool = false;
					break;
				}
			}
		} {
			int num =a[i];
			if(num % 2 == 0) {
				if(num % 3 != 0 && num % 5 != 0) {
					bool = false;
					break;
				}
			}
		} int num =a[i]; num a[i] a i if(num % 2 == 0) {
				if(num % 3 != 0 && num % 5 != 0) {
					bool = false;
					break;
				}
			} num % 2 == 0 num % 2 num 2 0 {
				if(num % 3 != 0 && num % 5 != 0) {
					bool = false;
					break;
				}
			} if(num % 3 != 0 && num % 5 != 0) {
					bool = false;
					break;
				} num % 3 != 0 && num % 5 != 0 num % 3 != 0 num % 3 num 3 0 num % 5 != 0 num % 5 num 5 0 {
					bool = false;
					break;
				} bool = false bool false break; if(bool) {
			System.out.println("APPROVED");
		}else {
			System.out.println("DENIED");
		} bool {
			System.out.println("APPROVED");
		} System.out.println("APPROVED") System.out.println System.out System System.out "APPROVED" {
			System.out.println("DENIED");
		} System.out.println("DENIED") System.out.println System.out System System.out "DENIED" sc.close() sc.close sc 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];
		for(int i = 0; i < n; i++) {
			a[i] = sc.nextInt();
		}
		
		boolean  bool = true; 
		for(int i = 0; i < n; i++) {
			int num =a[i];
			if(num % 2 == 0) {
				if(num % 3 != 0 && num % 5 != 0) {
					bool = false;
					break;
				}
			}
		}
		
		if(bool) {
			System.out.println("APPROVED");
		}else {
			System.out.println("DENIED");
		}
		
		sc.close();
	}
} public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int[] a = new int[n];
		for(int i = 0; i < n; i++) {
			a[i] = sc.nextInt();
		}
		
		boolean  bool = true; 
		for(int i = 0; i < n; i++) {
			int num =a[i];
			if(num % 2 == 0) {
				if(num % 3 != 0 && num % 5 != 0) {
					bool = false;
					break;
				}
			}
		}
		
		if(bool) {
			System.out.println("APPROVED");
		}else {
			System.out.println("DENIED");
		}
		
		sc.close();
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int[] a = new int[n];
		for(int i = 0; i < n; i++) {
			a[i] = sc.nextInt();
		}
		
		boolean  bool = true; 
		for(int i = 0; i < n; i++) {
			int num =a[i];
			if(num % 2 == 0) {
				if(num % 3 != 0 && num % 5 != 0) {
					bool = false;
					break;
				}
			}
		}
		
		if(bool) {
			System.out.println("APPROVED");
		}else {
			System.out.println("DENIED");
		}
		
		sc.close();
	}
}