import java.io.InputStream;
import java.io.PrintStream;
import java.util.*;

public class Main {
    public static void main(String[] args) throws Exception {
        solve(System.in, System.out);
    }

    static void solve(InputStream is, PrintStream os) {
        // Your code here!
        Scanner scan = new Scanner(is);
        int N = scan.nextInt();

        for(int i = 0; i < N; i ++){
            int A = scan.nextInt();
            if(A%2 == 0 && (A%3 != 0 && A%5 != 0)) {
                os.println("DENIED");
                return;
            }
        }

        os.println("APPROVED");
    }
} import java.io.InputStream; InputStream java.io import java.io.PrintStream; PrintStream java.io import java.util.*; util.* java public class Main {
    public static void main(String[] args) throws Exception {
        solve(System.in, System.out);
    }

    static void solve(InputStream is, PrintStream os) {
        // Your code here!
        Scanner scan = new Scanner(is);
        int N = scan.nextInt();

        for(int i = 0; i < N; i ++){
            int A = scan.nextInt();
            if(A%2 == 0 && (A%3 != 0 && A%5 != 0)) {
                os.println("DENIED");
                return;
            }
        }

        os.println("APPROVED");
    }
} Main public static void main(String[] args) throws Exception {
        solve(System.in, System.out);
    } main {
        solve(System.in, System.out);
    } solve(System.in, System.out) solve System.in System System.in System.out System System.out String[] args args static void solve(InputStream is, PrintStream os) {
        // Your code here!
        Scanner scan = new Scanner(is);
        int N = scan.nextInt();

        for(int i = 0; i < N; i ++){
            int A = scan.nextInt();
            if(A%2 == 0 && (A%3 != 0 && A%5 != 0)) {
                os.println("DENIED");
                return;
            }
        }

        os.println("APPROVED");
    } solve {
        // Your code here!
        Scanner scan = new Scanner(is);
        int N = scan.nextInt();

        for(int i = 0; i < N; i ++){
            int A = scan.nextInt();
            if(A%2 == 0 && (A%3 != 0 && A%5 != 0)) {
                os.println("DENIED");
                return;
            }
        }

        os.println("APPROVED");
    } Scanner scan = new Scanner(is); scan new Scanner(is) int N = scan.nextInt(); N scan.nextInt() scan.nextInt scan for(int i = 0; i < N; i ++){
            int A = scan.nextInt();
            if(A%2 == 0 && (A%3 != 0 && A%5 != 0)) {
                os.println("DENIED");
                return;
            }
        } int i = 0; int i = 0; i 0 i < N i N i ++ i ++ i {
            int A = scan.nextInt();
            if(A%2 == 0 && (A%3 != 0 && A%5 != 0)) {
                os.println("DENIED");
                return;
            }
        } {
            int A = scan.nextInt();
            if(A%2 == 0 && (A%3 != 0 && A%5 != 0)) {
                os.println("DENIED");
                return;
            }
        } int A = scan.nextInt(); A scan.nextInt() scan.nextInt scan if(A%2 == 0 && (A%3 != 0 && A%5 != 0)) {
                os.println("DENIED");
                return;
            } A%2 == 0 && (A%3 != 0 && A%5 != 0) A%2 == 0 A%2 A 2 0 (A%3 != 0 && A%5 != 0) A%3 != 0 A%3 A 3 0 A%5 != 0 A%5 A 5 0 {
                os.println("DENIED");
                return;
            } os.println("DENIED") os.println os "DENIED" return; os.println("APPROVED") os.println os "APPROVED" InputStream is is PrintStream os os public class Main {
    public static void main(String[] args) throws Exception {
        solve(System.in, System.out);
    }

    static void solve(InputStream is, PrintStream os) {
        // Your code here!
        Scanner scan = new Scanner(is);
        int N = scan.nextInt();

        for(int i = 0; i < N; i ++){
            int A = scan.nextInt();
            if(A%2 == 0 && (A%3 != 0 && A%5 != 0)) {
                os.println("DENIED");
                return;
            }
        }

        os.println("APPROVED");
    }
} public class Main {
    public static void main(String[] args) throws Exception {
        solve(System.in, System.out);
    }

    static void solve(InputStream is, PrintStream os) {
        // Your code here!
        Scanner scan = new Scanner(is);
        int N = scan.nextInt();

        for(int i = 0; i < N; i ++){
            int A = scan.nextInt();
            if(A%2 == 0 && (A%3 != 0 && A%5 != 0)) {
                os.println("DENIED");
                return;
            }
        }

        os.println("APPROVED");
    }
} Main
import java.io.InputStream;
import java.io.PrintStream;
import java.util.*;

public class Main {
    public static void main(String[] args) throws Exception {
        solve(System.in, System.out);
    }

    static void solve(InputStream is, PrintStream os) {
        // Your code here!
        Scanner scan = new Scanner(is);
        int N = scan.nextInt();

        for(int i = 0; i < N; i ++){
            int A = scan.nextInt();
            if(A%2 == 0 && (A%3 != 0 && A%5 != 0)) {
                os.println("DENIED");
                return;
            }
        }

        os.println("APPROVED");
    }
}