import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.io.IOException;
import java.util.*;

public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
    int K = Integer.parseInt(in.readLine());
    StringTokenizer st = new StringTokenizer(in.readLine());
    int A = Integer.parseInt(st.nextToken());
    int B = Integer.parseInt(st.nextToken());
    for(int score=A; score<=B; score++){
      if(score%K==0){
        System.out.println("OK");
        break;
      } else if(score==B && score%K!=0){
        System.out.println("NG");
      }
    }
  }
} import java.io.BufferedReader; BufferedReader java.io import java.io.InputStreamReader; InputStreamReader java.io import java.io.IOException; IOException java.io import java.util.*; util.* java public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
    int K = Integer.parseInt(in.readLine());
    StringTokenizer st = new StringTokenizer(in.readLine());
    int A = Integer.parseInt(st.nextToken());
    int B = Integer.parseInt(st.nextToken());
    for(int score=A; score<=B; score++){
      if(score%K==0){
        System.out.println("OK");
        break;
      } else if(score==B && score%K!=0){
        System.out.println("NG");
      }
    }
  }
} Main public static void main(String[] args) throws IOException {
    BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
    int K = Integer.parseInt(in.readLine());
    StringTokenizer st = new StringTokenizer(in.readLine());
    int A = Integer.parseInt(st.nextToken());
    int B = Integer.parseInt(st.nextToken());
    for(int score=A; score<=B; score++){
      if(score%K==0){
        System.out.println("OK");
        break;
      } else if(score==B && score%K!=0){
        System.out.println("NG");
      }
    }
  } main {
    BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
    int K = Integer.parseInt(in.readLine());
    StringTokenizer st = new StringTokenizer(in.readLine());
    int A = Integer.parseInt(st.nextToken());
    int B = Integer.parseInt(st.nextToken());
    for(int score=A; score<=B; score++){
      if(score%K==0){
        System.out.println("OK");
        break;
      } else if(score==B && score%K!=0){
        System.out.println("NG");
      }
    }
  } BufferedReader in = new BufferedReader(new InputStreamReader(System.in)); in new BufferedReader(new InputStreamReader(System.in)) int K = Integer.parseInt(in.readLine()); K Integer.parseInt(in.readLine()) Integer.parseInt Integer in.readLine() in.readLine in StringTokenizer st = new StringTokenizer(in.readLine()); st new StringTokenizer(in.readLine()) int A = Integer.parseInt(st.nextToken()); A Integer.parseInt(st.nextToken()) Integer.parseInt Integer st.nextToken() st.nextToken st int B = Integer.parseInt(st.nextToken()); B Integer.parseInt(st.nextToken()) Integer.parseInt Integer st.nextToken() st.nextToken st for(int score=A; score<=B; score++){
      if(score%K==0){
        System.out.println("OK");
        break;
      } else if(score==B && score%K!=0){
        System.out.println("NG");
      }
    } int score=A; int score=A; score A score<=B score B score++ score++ score {
      if(score%K==0){
        System.out.println("OK");
        break;
      } else if(score==B && score%K!=0){
        System.out.println("NG");
      }
    } {
      if(score%K==0){
        System.out.println("OK");
        break;
      } else if(score==B && score%K!=0){
        System.out.println("NG");
      }
    } if(score%K==0){
        System.out.println("OK");
        break;
      } else if(score==B && score%K!=0){
        System.out.println("NG");
      } score%K==0 score%K score K 0 {
        System.out.println("OK");
        break;
      } System.out.println("OK") System.out.println System.out System System.out "OK" break; if(score==B && score%K!=0){
        System.out.println("NG");
      } score==B && score%K!=0 score==B score B score%K!=0 score%K score K 0 {
        System.out.println("NG");
      } System.out.println("NG") System.out.println System.out System System.out "NG" String[] args args public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
    int K = Integer.parseInt(in.readLine());
    StringTokenizer st = new StringTokenizer(in.readLine());
    int A = Integer.parseInt(st.nextToken());
    int B = Integer.parseInt(st.nextToken());
    for(int score=A; score<=B; score++){
      if(score%K==0){
        System.out.println("OK");
        break;
      } else if(score==B && score%K!=0){
        System.out.println("NG");
      }
    }
  }
} public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
    int K = Integer.parseInt(in.readLine());
    StringTokenizer st = new StringTokenizer(in.readLine());
    int A = Integer.parseInt(st.nextToken());
    int B = Integer.parseInt(st.nextToken());
    for(int score=A; score<=B; score++){
      if(score%K==0){
        System.out.println("OK");
        break;
      } else if(score==B && score%K!=0){
        System.out.println("NG");
      }
    }
  }
} Main
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.io.IOException;
import java.util.*;

public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
    int K = Integer.parseInt(in.readLine());
    StringTokenizer st = new StringTokenizer(in.readLine());
    int A = Integer.parseInt(st.nextToken());
    int B = Integer.parseInt(st.nextToken());
    for(int score=A; score<=B; score++){
      if(score%K==0){
        System.out.println("OK");
        break;
      } else if(score==B && score%K!=0){
        System.out.println("NG");
      }
    }
  }
}