import java.util.*;
public class Main{
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[] num = new int[n];
        int cnt=0;


        for(int i = 0;i<n;i++){
            num[i]=sc.nextInt();
        }

        for(int i = 0;i<n;i++){
            if(num[i]%2==0 && (num[i]%3)!=0 && (num[i]%5) !=0){
                cnt++;
            }
        }

        if(cnt==0){
            System.out.println("APPROVED");
        }else{
            System.out.println("DENIED");
        }

    }
} import java.util.*; util.* java public class Main{
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[] num = new int[n];
        int cnt=0;


        for(int i = 0;i<n;i++){
            num[i]=sc.nextInt();
        }

        for(int i = 0;i<n;i++){
            if(num[i]%2==0 && (num[i]%3)!=0 && (num[i]%5) !=0){
                cnt++;
            }
        }

        if(cnt==0){
            System.out.println("APPROVED");
        }else{
            System.out.println("DENIED");
        }

    }
} Main public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[] num = new int[n];
        int cnt=0;


        for(int i = 0;i<n;i++){
            num[i]=sc.nextInt();
        }

        for(int i = 0;i<n;i++){
            if(num[i]%2==0 && (num[i]%3)!=0 && (num[i]%5) !=0){
                cnt++;
            }
        }

        if(cnt==0){
            System.out.println("APPROVED");
        }else{
            System.out.println("DENIED");
        }

    } main {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[] num = new int[n];
        int cnt=0;


        for(int i = 0;i<n;i++){
            num[i]=sc.nextInt();
        }

        for(int i = 0;i<n;i++){
            if(num[i]%2==0 && (num[i]%3)!=0 && (num[i]%5) !=0){
                cnt++;
            }
        }

        if(cnt==0){
            System.out.println("APPROVED");
        }else{
            System.out.println("DENIED");
        }

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


        for(int i = 0;i<n;i++){
            num[i]=sc.nextInt();
        }

        for(int i = 0;i<n;i++){
            if(num[i]%2==0 && (num[i]%3)!=0 && (num[i]%5) !=0){
                cnt++;
            }
        }

        if(cnt==0){
            System.out.println("APPROVED");
        }else{
            System.out.println("DENIED");
        }

    }
} public class Main{
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[] num = new int[n];
        int cnt=0;


        for(int i = 0;i<n;i++){
            num[i]=sc.nextInt();
        }

        for(int i = 0;i<n;i++){
            if(num[i]%2==0 && (num[i]%3)!=0 && (num[i]%5) !=0){
                cnt++;
            }
        }

        if(cnt==0){
            System.out.println("APPROVED");
        }else{
            System.out.println("DENIED");
        }

    }
} Main
import java.util.*;
public class Main{
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[] num = new int[n];
        int cnt=0;


        for(int i = 0;i<n;i++){
            num[i]=sc.nextInt();
        }

        for(int i = 0;i<n;i++){
            if(num[i]%2==0 && (num[i]%3)!=0 && (num[i]%5) !=0){
                cnt++;
            }
        }

        if(cnt==0){
            System.out.println("APPROVED");
        }else{
            System.out.println("DENIED");
        }

    }
}
