/* package whatever; // don't place package name! */

import java.util.*;
import java.lang.*;
import java.io.*;

/* Name of the class has to be "Main" only if the class is public. */
public class Main{
	public static void main (String[] args) throws java.lang.Exception
	{
		Scanner scan = new Scanner(System.in);
		int n= scan.nextInt();
		int[] arr = new int[n];
		for(int i =0 ;i<n;i++){
			arr[i] = scan.nextInt();
		}
		int flag = 0;
		for(int j : arr){
			if((j%2)==0 && ((j%3)!=0) &&((j%5)!=0)){
				flag = 1;
				break;
			}
		}
		String ans = (flag==1)?"DENIED":"APPROVED";
		System.out.println(ans);
		// your code goes here
	}
} import java.util.*; util.* java import java.lang.*; lang.* java import java.io.*; io.* java public class Main{
	public static void main (String[] args) throws java.lang.Exception
	{
		Scanner scan = new Scanner(System.in);
		int n= scan.nextInt();
		int[] arr = new int[n];
		for(int i =0 ;i<n;i++){
			arr[i] = scan.nextInt();
		}
		int flag = 0;
		for(int j : arr){
			if((j%2)==0 && ((j%3)!=0) &&((j%5)!=0)){
				flag = 1;
				break;
			}
		}
		String ans = (flag==1)?"DENIED":"APPROVED";
		System.out.println(ans);
		// your code goes here
	}
} Main public static void main (String[] args) throws java.lang.Exception
	{
		Scanner scan = new Scanner(System.in);
		int n= scan.nextInt();
		int[] arr = new int[n];
		for(int i =0 ;i<n;i++){
			arr[i] = scan.nextInt();
		}
		int flag = 0;
		for(int j : arr){
			if((j%2)==0 && ((j%3)!=0) &&((j%5)!=0)){
				flag = 1;
				break;
			}
		}
		String ans = (flag==1)?"DENIED":"APPROVED";
		System.out.println(ans);
		// your code goes here
	} main {
		Scanner scan = new Scanner(System.in);
		int n= scan.nextInt();
		int[] arr = new int[n];
		for(int i =0 ;i<n;i++){
			arr[i] = scan.nextInt();
		}
		int flag = 0;
		for(int j : arr){
			if((j%2)==0 && ((j%3)!=0) &&((j%5)!=0)){
				flag = 1;
				break;
			}
		}
		String ans = (flag==1)?"DENIED":"APPROVED";
		System.out.println(ans);
		// your code goes here
	} Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int n= scan.nextInt(); n scan.nextInt() scan.nextInt scan int[] arr = new int[n]; arr new int[n] n for(int i =0 ;i<n;i++){
			arr[i] = scan.nextInt();
		} int i =0 ; int i =0 ; i 0 i<n i n i++ i++ i {
			arr[i] = scan.nextInt();
		} {
			arr[i] = scan.nextInt();
		} arr[i] = scan.nextInt() arr[i] arr i scan.nextInt() scan.nextInt scan int flag = 0; flag 0 for(int j : arr){
			if((j%2)==0 && ((j%3)!=0) &&((j%5)!=0)){
				flag = 1;
				break;
			}
		} int j arr {
			if((j%2)==0 && ((j%3)!=0) &&((j%5)!=0)){
				flag = 1;
				break;
			}
		} {
			if((j%2)==0 && ((j%3)!=0) &&((j%5)!=0)){
				flag = 1;
				break;
			}
		} if((j%2)==0 && ((j%3)!=0) &&((j%5)!=0)){
				flag = 1;
				break;
			} (j%2)==0 && ((j%3)!=0) &&((j%5)!=0) (j%2)==0 && ((j%3)!=0) &&((j%5)!=0) (j%2)==0 (j%2) j 2 0 ((j%3)!=0) (j%3) j 3 0 ((j%5)!=0) (j%5) j 5 0 {
				flag = 1;
				break;
			} flag = 1 flag 1 break; String ans = (flag==1)?"DENIED":"APPROVED"; ans (flag==1)?"DENIED":"APPROVED" (flag==1) flag 1 "DENIED" "APPROVED" System.out.println(ans) System.out.println System.out System System.out ans String[] args args public class Main{
	public static void main (String[] args) throws java.lang.Exception
	{
		Scanner scan = new Scanner(System.in);
		int n= scan.nextInt();
		int[] arr = new int[n];
		for(int i =0 ;i<n;i++){
			arr[i] = scan.nextInt();
		}
		int flag = 0;
		for(int j : arr){
			if((j%2)==0 && ((j%3)!=0) &&((j%5)!=0)){
				flag = 1;
				break;
			}
		}
		String ans = (flag==1)?"DENIED":"APPROVED";
		System.out.println(ans);
		// your code goes here
	}
} public class Main{
	public static void main (String[] args) throws java.lang.Exception
	{
		Scanner scan = new Scanner(System.in);
		int n= scan.nextInt();
		int[] arr = new int[n];
		for(int i =0 ;i<n;i++){
			arr[i] = scan.nextInt();
		}
		int flag = 0;
		for(int j : arr){
			if((j%2)==0 && ((j%3)!=0) &&((j%5)!=0)){
				flag = 1;
				break;
			}
		}
		String ans = (flag==1)?"DENIED":"APPROVED";
		System.out.println(ans);
		// your code goes here
	}
} Main
/* package whatever; // don't place package name! */

import java.util.*;
import java.lang.*;
import java.io.*;

/* Name of the class has to be "Main" only if the class is public. */
public class Main{
	public static void main (String[] args) throws java.lang.Exception
	{
		Scanner scan = new Scanner(System.in);
		int n= scan.nextInt();
		int[] arr = new int[n];
		for(int i =0 ;i<n;i++){
			arr[i] = scan.nextInt();
		}
		int flag = 0;
		for(int j : arr){
			if((j%2)==0 && ((j%3)!=0) &&((j%5)!=0)){
				flag = 1;
				break;
			}
		}
		String ans = (flag==1)?"DENIED":"APPROVED";
		System.out.println(ans);
		// your code goes here
	}
}