import java.util.*;

public class Main {
    public static void main(String[] args) throws Exception {
        String[] lines = getStdin();
        String str1 = lines[0];
        int mult = Integer.parseInt(str1); //K
        
        String str2 = lines[1];
        String[] str21 = str2.split(" ");
        int from = Integer.parseInt(str21[0]); //A
        int till = Integer.parseInt(str21[1]); //B

        for (int i = 1; i <= 1000 ; i++){
            int multiple = mult * i ;
            //System.out.println(multiple);
            if (multiple >= from && multiple <= till){
                System.out.println("OK");
                return;
            } else {
                multiple = mult; //=7
            }
        }

        System.out.println("NG");


   
    
    
        
    }
  
  private static String[] getStdin() {
    Scanner scanner = new Scanner(System.in);
    ArrayList<String> lines = new ArrayList<>();
    while (scanner.hasNext()) {
      lines.add(scanner.nextLine());
    }
    return lines.toArray(new String[lines.size()]);
  }
  
} import java.util.*; util.* java public class Main {
    public static void main(String[] args) throws Exception {
        String[] lines = getStdin();
        String str1 = lines[0];
        int mult = Integer.parseInt(str1); //K
        
        String str2 = lines[1];
        String[] str21 = str2.split(" ");
        int from = Integer.parseInt(str21[0]); //A
        int till = Integer.parseInt(str21[1]); //B

        for (int i = 1; i <= 1000 ; i++){
            int multiple = mult * i ;
            //System.out.println(multiple);
            if (multiple >= from && multiple <= till){
                System.out.println("OK");
                return;
            } else {
                multiple = mult; //=7
            }
        }

        System.out.println("NG");


   
    
    
        
    }
  
  private static String[] getStdin() {
    Scanner scanner = new Scanner(System.in);
    ArrayList<String> lines = new ArrayList<>();
    while (scanner.hasNext()) {
      lines.add(scanner.nextLine());
    }
    return lines.toArray(new String[lines.size()]);
  }
  
} Main public static void main(String[] args) throws Exception {
        String[] lines = getStdin();
        String str1 = lines[0];
        int mult = Integer.parseInt(str1); //K
        
        String str2 = lines[1];
        String[] str21 = str2.split(" ");
        int from = Integer.parseInt(str21[0]); //A
        int till = Integer.parseInt(str21[1]); //B

        for (int i = 1; i <= 1000 ; i++){
            int multiple = mult * i ;
            //System.out.println(multiple);
            if (multiple >= from && multiple <= till){
                System.out.println("OK");
                return;
            } else {
                multiple = mult; //=7
            }
        }

        System.out.println("NG");


   
    
    
        
    } main {
        String[] lines = getStdin();
        String str1 = lines[0];
        int mult = Integer.parseInt(str1); //K
        
        String str2 = lines[1];
        String[] str21 = str2.split(" ");
        int from = Integer.parseInt(str21[0]); //A
        int till = Integer.parseInt(str21[1]); //B

        for (int i = 1; i <= 1000 ; i++){
            int multiple = mult * i ;
            //System.out.println(multiple);
            if (multiple >= from && multiple <= till){
                System.out.println("OK");
                return;
            } else {
                multiple = mult; //=7
            }
        }

        System.out.println("NG");


   
    
    
        
    } String[] lines = getStdin(); lines getStdin() getStdin String str1 = lines[0]; str1 lines[0] lines 0 int mult = Integer.parseInt(str1); mult Integer.parseInt(str1) Integer.parseInt Integer str1 String str2 = lines[1]; str2 lines[1] lines 1 String[] str21 = str2.split(" "); str21 str2.split(" ") str2.split str2 " " int from = Integer.parseInt(str21[0]); from Integer.parseInt(str21[0]) Integer.parseInt Integer str21[0] str21 0 int till = Integer.parseInt(str21[1]); till Integer.parseInt(str21[1]) Integer.parseInt Integer str21[1] str21 1 for (int i = 1; i <= 1000 ; i++){
            int multiple = mult * i ;
            //System.out.println(multiple);
            if (multiple >= from && multiple <= till){
                System.out.println("OK");
                return;
            } else {
                multiple = mult; //=7
            }
        } int i = 1; int i = 1; i 1 i <= 1000 i 1000 i++ i++ i {
            int multiple = mult * i ;
            //System.out.println(multiple);
            if (multiple >= from && multiple <= till){
                System.out.println("OK");
                return;
            } else {
                multiple = mult; //=7
            }
        } {
            int multiple = mult * i ;
            //System.out.println(multiple);
            if (multiple >= from && multiple <= till){
                System.out.println("OK");
                return;
            } else {
                multiple = mult; //=7
            }
        } int multiple = mult * i ; multiple mult * i mult i if (multiple >= from && multiple <= till){
                System.out.println("OK");
                return;
            } else {
                multiple = mult; //=7
            } multiple >= from && multiple <= till multiple >= from multiple from multiple <= till multiple till {
                System.out.println("OK");
                return;
            } System.out.println("OK") System.out.println System.out System System.out "OK" return; {
                multiple = mult; //=7
            } multiple = mult multiple mult System.out.println("NG") System.out.println System.out System System.out "NG" String[] args args private static String[] getStdin() {
    Scanner scanner = new Scanner(System.in);
    ArrayList<String> lines = new ArrayList<>();
    while (scanner.hasNext()) {
      lines.add(scanner.nextLine());
    }
    return lines.toArray(new String[lines.size()]);
  } getStdin {
    Scanner scanner = new Scanner(System.in);
    ArrayList<String> lines = new ArrayList<>();
    while (scanner.hasNext()) {
      lines.add(scanner.nextLine());
    }
    return lines.toArray(new String[lines.size()]);
  } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) ArrayList<String> lines = new ArrayList<>(); lines new ArrayList<>() while (scanner.hasNext()) {
      lines.add(scanner.nextLine());
    } scanner.hasNext() scanner.hasNext scanner {
      lines.add(scanner.nextLine());
    } lines.add(scanner.nextLine()) lines.add lines scanner.nextLine() scanner.nextLine scanner return lines.toArray(new String[lines.size()]); lines.toArray(new String[lines.size()]) lines.toArray lines new String[lines.size()] lines.size() lines.size lines public class Main {
    public static void main(String[] args) throws Exception {
        String[] lines = getStdin();
        String str1 = lines[0];
        int mult = Integer.parseInt(str1); //K
        
        String str2 = lines[1];
        String[] str21 = str2.split(" ");
        int from = Integer.parseInt(str21[0]); //A
        int till = Integer.parseInt(str21[1]); //B

        for (int i = 1; i <= 1000 ; i++){
            int multiple = mult * i ;
            //System.out.println(multiple);
            if (multiple >= from && multiple <= till){
                System.out.println("OK");
                return;
            } else {
                multiple = mult; //=7
            }
        }

        System.out.println("NG");


   
    
    
        
    }
  
  private static String[] getStdin() {
    Scanner scanner = new Scanner(System.in);
    ArrayList<String> lines = new ArrayList<>();
    while (scanner.hasNext()) {
      lines.add(scanner.nextLine());
    }
    return lines.toArray(new String[lines.size()]);
  }
  
} public class Main {
    public static void main(String[] args) throws Exception {
        String[] lines = getStdin();
        String str1 = lines[0];
        int mult = Integer.parseInt(str1); //K
        
        String str2 = lines[1];
        String[] str21 = str2.split(" ");
        int from = Integer.parseInt(str21[0]); //A
        int till = Integer.parseInt(str21[1]); //B

        for (int i = 1; i <= 1000 ; i++){
            int multiple = mult * i ;
            //System.out.println(multiple);
            if (multiple >= from && multiple <= till){
                System.out.println("OK");
                return;
            } else {
                multiple = mult; //=7
            }
        }

        System.out.println("NG");


   
    
    
        
    }
  
  private static String[] getStdin() {
    Scanner scanner = new Scanner(System.in);
    ArrayList<String> lines = new ArrayList<>();
    while (scanner.hasNext()) {
      lines.add(scanner.nextLine());
    }
    return lines.toArray(new String[lines.size()]);
  }
  
} Main
import java.util.*;

public class Main {
    public static void main(String[] args) throws Exception {
        String[] lines = getStdin();
        String str1 = lines[0];
        int mult = Integer.parseInt(str1); //K
        
        String str2 = lines[1];
        String[] str21 = str2.split(" ");
        int from = Integer.parseInt(str21[0]); //A
        int till = Integer.parseInt(str21[1]); //B

        for (int i = 1; i <= 1000 ; i++){
            int multiple = mult * i ;
            //System.out.println(multiple);
            if (multiple >= from && multiple <= till){
                System.out.println("OK");
                return;
            } else {
                multiple = mult; //=7
            }
        }

        System.out.println("NG");


   
    
    
        
    }
  
  private static String[] getStdin() {
    Scanner scanner = new Scanner(System.in);
    ArrayList<String> lines = new ArrayList<>();
    while (scanner.hasNext()) {
      lines.add(scanner.nextLine());
    }
    return lines.toArray(new String[lines.size()]);
  }
  
}
