Problem:
 Score: 100 points    Problem Statement  Takahashi the Jumbo will practice golf.  His objective is to get a carry distance that is a multiple of K , while he can only make a carry distance of between A and B (inclusive).  If he can achieve the objective, print OK ; if he cannot, print NG .      Constraints   All values in input are integers.  1 \leq A \leq B \leq 1000  1 \leq K \leq 1000         Input  Input is given from Standard Input in the following format:  K  A  B       Output  If he can achieve the objective, print OK ; if he cannot, print NG .        Sample Input 1 7
500 600      Sample Output 1 OK  Among the multiples of 7 , for example, 567 lies between 500 and 600 .       Sample Input 2 4
5 7      Sample Output 2 NG  No multiple of 4 lies between 5 and 7 .       Sample Input 3 1
11 11      Sample Output 3 OK

Solution (Python):
n = int(input())
a, b = input().split()
a = int(a)
b = int(b)

if a %n == 0:
  print('OK')
else:
  rem = a % n
  if b >= a + n - rem:
      print('OK')
  else:
      print('NG')

Solution (Python):
input = raw_input

k = int(input())
a, b = map(int, input().split(" "))

if b-a >= k:
    out = "OK"
else:
    ak = a % k
    bk = b % k
    if 0 in [ak, bk]:
        out = "OK"
    elif bk < ak:
        out = "OK"
    else:
        out = "NG"

print(out)

Solution (Python):
k = int(input())
a,b = map(int,input().split())

for i in range(a, b+1):
    if i % k == 0:
        print("OK")
        exit()
print("NG")

Solution (Python):
k = int(input())
a, b = map(int, input().split())
flag = False
for i in range(a, b + 1):
    if i % k == 0:
        flag = True
print('OK' if flag else 'NG')

Solution (Python):
k=int(input())
a,b=map(int, input().split())
val=0
for i in range(a,b+1):
    if i%k==0:
        val=1
        break
if val==1:
    print("OK")
else:
    print("NG")

Solution (Python):
K = int(input())
A, B = map(int, input().split())

cnt = 0
for i in range(A, B+1):
    if i % K == 0:
        cnt = 1
        print('OK')
        break
if cnt == 0:
    print('NG')

Solution (Python):
k = int(input())

a,b = map(int, input().split())

if a // k != b // k or a % k == 0:
    print("OK")
else:
    print("NG")

Solution (Python):
import sys
from collections import defaultdict, Counter, deque
from itertools import accumulate, permutations, combinations
from operator import itemgetter
from bisect import bisect_left, bisect_right, bisect
from heapq import heappop, heappush
from fractions import gcd
from math import ceil, floor, sqrt, cos, sin, pi
from copy import deepcopy




def main():
    k = int(input())
    a,b = map(int, input().split())
    ans = k*(a//k + (a%k!=0))
    if ans <= b:
        print("OK")
    else:
        print("NG")
        

if __name__ == '__main__':
    main()

Solution (Python):
k=int(input())
a,b = map(int,input().split())
ans = 0
while True:
    ans += k
    if a<=ans<=b:
        print("OK")
        break
    if b <ans:
        print("NG")
        break

Solution (Python):
k = int(input())
a, b = map(int, input().split())
for i in range(a, b+1):
    if i % k == 0:
        print("OK")
        quit()
print("NG")

Solution (Python):

"""
Created on Sat May  2 20:56:46 2020
"""

import sys


sys.setrecursionlimit(10 ** 9)


mod = 10**9+7

K = int(input())
A, B = map(int,input().split())








ans = 'NG'
if A % K == 0 or B % K == 0:
    ans ='OK'
for i in range(A,B+1):
    if i % K == 0:
        ans = 'OK'
print(ans)

Solution (Python):
K=int(input())
A,B=map(int,input().split())
tmp=0
for i in range(B+1):
    if A<=tmp and tmp<=B:
        print("OK")
        exit()
    tmp+=K

print("NG")

Solution (Python):
N=int(input())
a,b=map(int,input().split())

count=0
for i in range(a,b+1):
  if i%N==0:
    count+=1
if count>=1:
  print("OK")
else:
  print("NG")

Solution (Python):
K = int(input())
A, B = map(int, input().split())

for i in range(A, B+1):
  if i % K == 0:
    print('OK')
    break
else:
  print('NG')

Solution (Python):
k = int(input())
a, b = map(int, input().split())

for i in range(a, b + 1):
    if i % k == 0:
        print('OK')
        exit()

print('NG')

Solution (Python):
K = int(input())
A, B = map(int, input().split())
if A % K == 0:
    print('OK')
else:
    N = ((A // K) + 1) * K
    if N <= B:
        print('OK')
    else:
        print('NG')

Solution (Python):
k=int(input())
a,b=map(int,input().split())
if a<=(b//k)*k:
  print("OK")
else:
  print("NG")

Solution (Python):
K = int(input())
A,B = map(int,input().split())


for i in range(A,B+1):
    if i%K==0:
        print('OK')
        exit()
print('NG')

Solution (Python):


import sys
stdin = sys.stdin

def ns(): return stdin.readline().rstrip()
def ni(): return int(ns())
def na(): return list(map(int, stdin.readline().split()))

def main():
    k = ni()
    a, b = na()
    c = a % k

    if a + (k - c) <= b or c == 0:
        print("OK")
    else:
        print("NG")

if __name__ == "__main__":
    main()

Solution (Python):
k=int(input())
a,b=map(int,input().split())
ans=0
for i in range(b+1):
  if a<=i*k<=b:
    ans=1
    break
if ans==0:
  print('NG')
else:
  print('OK')

Solution (Python):
k = int(input())
a, b = map(int, input().split())

for i in range(a, b+1):
    if i % k == 0:
        print('OK')
        exit()
    else:
        continue
    
print('NG')

Solution (Python):
k = int(input())
a, b = map(int, input().split())
ans = "NG"
for i in range(a, b + 1):
    if i % k == 0:
        ans = "OK"
        break
print(ans)

Solution (Python):
a=int(input())
s,e=map(int,input().split())
for i in range(s,e+1):
    if i%a==0:
        print("OK")
        break
else:
    print("NG")

Solution (Python):
import sys
K = int(input())
A, B = map(int, input().split())
for i in range(A, B+1):
    if i%K == 0:
        print('OK')
        sys.exit()
print('NG')

Solution (Python):
k = int(input())
a, b = map(int, input().split())
for i in range(a, b+1):
    if i % k == 0:
        print("OK")
        break
else:
    print("NG")

Solution (Python):
K = int(input())

A, B = [int(i) for i in input().split()]

flag = False
for i in range(A, B+1):
    if i % K == 0:
        flag = True
        break
        
if flag :
    print('OK')
else :
    print('NG')

Solution (Python):
k = int(input())
A,B = map(int,input().split())

flag = 0
for i in range(A,B+1):
    if i%k==0:
        flag=1

ans = 'OK' if flag==1 else 'NG'
print(ans)

Solution (Python):
def main():
    k = int(input())
    a,b = (int(x) for x in input().split())
    for i in range(a, b+1):
        if i%k == 0:
            print('OK')
            break
    else:
        print('NG')

if __name__ == '__main__':
    main()

Solution (Python):
K = int(input())
A, B = map(int, input().split())

if A % K == 0 or (A <= (A // K + 1) * K <= B):
    print("OK")
else:
    print("NG")

Solution (Python):
k=int(input())
a,b=map(int,input().split())
flag=False
for i in range(a,b+1):
    if i%k==0:
        flag=True
        break
if flag:
    print('OK')
else:
    print('NG')

Solution (Python):


from queue import Queue
from queue import LifoQueue as Stack
from math import sqrt, floor, ceil, log2, log10, pi
from fractions import gcd
from itertools import permutations, combinations
from operator import itemgetter
from functools import cmp_to_key


INF=1001001001
__MOD__=(10**9)+7
yn = 'YNeos'
judge = False
cnt = 0
ans = None


def lcm(a, b):
    return (a*b) // gcd(a,b)

def intinput():
    return int(input())

def mulinputs():
    return map(int,input().split())

def lineinputs(func=intinput):
    datas = []
    while True:
        try:
            datas.append(func())
        except EOFError:
            break
    return datas

class ModInt():
    def __init__(self, x):
        self.__x = (x % __MOD__)
    def __add__(self, other):
        if type(other) == int:
            other = self.__class__(other)
            return int(self.__class__((self.__x + other.__x)%__MOD__))
        elif type(other) == ModInt:
            return self.__class__((self.__x + other.__x)%__MOD__)
        else:
            raise Exception("Not Int or Not ModInt")
    def __radd__(self, other):
        if type(other) == int:
            other = self.__class__(other)
            return int(self.__class__((other.__x + self.__x)%__MOD__))
        elif type(other) == ModInt:
            return self.__class__((other.__x + self.__x)%__MOD__)
        else:
            raise Exception("Not Int or Not ModInt")

    def __sub__(self, other):
        if type(other) == int:
            other = self.__class__(other)
            return int(self.__class__((self.__x - other.__x)%__MOD__))
        elif type(other) == ModInt:
            return self.__class__((self.__x - other.__x)%__MOD__)
        else:
            raise Exception("Not Int or Not ModInt")
    def __rsub__(self, other):
        if type(other) == int:
            other = self.__class__(other)
            return int(self.__class__((other.__x - self.__x)%__MOD__))
        elif type(other) == ModInt:
            return self.__class__((other.__x - self.__x)%__MOD__)
        else:
            raise Exception("Not Int or Not ModInt")

    def __mul__(self, other):
        if type(other) == int:
            other = self.__class__(other)
            return int(self.__class__((self.__x * other.__x)%__MOD__))
        elif type(other) == ModInt:
            return self.__class__((self.__x * other.__x)%__MOD__)
        else:
            raise Exception("Not Int or Not ModInt")
    def __rmul__(self, other):
        if type(other) == int:
            other = self.__class__(other)
            return int(self.__class__((other.__x * self.__x)%__MOD__))
        elif type(other) == ModInt:
            return self.__class__((other.__x * self.__x)%__MOD__)
        else:
            raise Exception("Not Int or Not ModInt")

    def __truediv__(self, other):
        if type(other) == int:
            other = self.__class__(other)
            return int(self.__class__((self.__x * other.__modinv())%__MOD__))
        elif type(other) == ModInt:
            return self.__class__((self.__x * other.__modinv())%__MOD__)
        else:
            raise Exception("Not Int or Not ModInt")
    def __rtruediv__(self, other):
        if type(other) == int:
            other = self.__class__(other)
            return int(self.__class__((other.__x * self.__modinv())%__MOD__))
        elif type(other) == ModInt:
            return self.__class__((other.__x * self.__modinv())%__MOD__)
        else:
            raise Exception("Not Int or Not ModInt")

    def __pow__(self, other):
        if type(other) == int:
            other = self.__class__(other)
            return int(self.__class__(pow(self.__x, other.__x, __MOD__)))
        elif type(other) == ModInt:
            return self.__class__(pow(self.__x, other.__x, __MOD__))
        else:
            raise Exception("Not Int or Not ModInt")
    def __rpow__(self, other):
        if type(other) == int:
            other = self.__class__(other)
            return int(self.__class__(pow(other.__x, self.__x, __MOD__)))
        elif type(other) == ModInt:
            return self.__class__(pow(other.__x, self.__x, __MOD__))
        else:
            raise Exception("Not Int or Not ModInt")

    def __modinv(self, m=__MOD__):
        a = self.__x
        if a == 0:
            raise ZeroDivisionError()
        if gcd(a, m) != 1:
            raise Exception("%sの逆数は求まりません。" % a)
        b, u, v = m, 1, 0
        while b != 0:
            t = a//b;
            a -= t*b
            a, b = b, a
            u -= t * v
            u, v = v, u
        u %= m
        if u < 0:
            u += m
        return u
    def __int__(self):
        return self.__x
    def __str__(self):
        return str(self.__x)



if __name__ == '__main__':
    N = intinput()
    A, B, = mulinputs()

    
    for i in range(A, B+1):
        if i % N == 0:
            print('OK')
            exit()
    print('NG')

Solution (Python):
k=int(input())
a,b=map(int,input().split())
g=0
for i in range(a,b+1):
  if i%k==0:
    g=1
    break
if g==1:
  print("OK")
else:
  print("NG")

Solution (Python):
K = int(input())
A, B = list(map(int, input().split()))

isOK = False

for n in range(A, B+1, 1):
    if n % K == 0:
        isOK = True

if isOK:
    print("OK")
else:
    print("NG")

Solution (Python):
import sys
k=int(input())
a,b=map(int,input().split())
for i in range(a,b+1):
    if i%k==0:
        print("OK")
        sys.exit()
print("NG")

Solution (Python):
k = int(input())
a,b = map(int,input().split())
for i in range(a, b+1):
  if i % k == 0:
    print("OK")
    exit()
print("NG")

Solution (Python):
k = int(input())
a, b = map(int, input().split())

if a % k == 0 or b//k != a//k:
    print("OK")
else:
    print("NG")

Solution (Python):
N = int(input())
A, B = map(int, input().split())
for i in range(A, B+1):
  if i % N == 0:
    print('OK')
    break
else:
  print('NG')

Solution (Python):
K = int(input())
a, b = map(int, input().split())
for i in range(a,b+1):
    if(i % K)==0:
        print('OK')
        exit()
else:
    print('NG')

Solution (Python):
p=0
K=int(input())
A,B=map(int,input().split())
for i in range(A,B+1):
  if i%K==0:
    print("OK")
    p=1
    break
if p!=1:
  print("NG")

Solution (Python):
K = int(input())
A,B = map(int,input().split())

ret = 'NG'
for i in range(A,B+1):
  if i % K == 0:
    ret = 'OK'

print(ret)

Solution (Python):
k = int(input())
a, b = map(int, input().split())
if a % k == 0:
    print('OK')
    exit()
if b // k > a // k:
    print('OK')
else:
    print('NG')

Solution (Python):
mod = 1000000007
eps = 10**-9


def main():
    import sys
    input = sys.stdin.readline

    K = int(input())
    A, B = map(int, input().split())
    ok = 0
    for k in range(A, B+1):
        if k % K == 0:
            ok = 1
            break
    if ok:
        print("OK")
    else:
        print("NG")


if __name__ == '__main__':
    main()

Solution (Python):
import sys
import math
import collections
from collections import deque
from functools import reduce
import heapq
k = int(input())
a, b = map(int, sys.stdin.readline().split())



for i in range(a, b+1):
    if i % k == 0:
        print("OK")
        sys.exit()

print("NG")

Solution (Python):
K = int(input())
A,B = map(int, input().split())

ans = 0

for i in range(A,B+1):
    if i % K == 0:
        ans = 1
        break
    
if ans == 1:
    print('OK')
else:
    print('NG')

Solution (Python):
k = int(input())
a, b = map(int, input().split())
for i in range(1001):
    if a <= k * i <= b:
        print("OK")
        break
else:
    print("NG")

Solution (Python):
K = int(input())
A,B = map(int,input().split())

for i in range(A,B+1):
    if i % K == 0:
        print('OK')
        exit()

print('NG')

Solution (Python):
k = int(input())
a, b = map(int, input().split())


for i in range(a, b+1):
    if(i % k == 0):
        print("OK")
        exit(0)
print("NG")

Solution (Python):
k=int(input())
a,b=map(int,input().split())
li=[i for i in range(a,b+1) if i%k==0]
if len(li)>=1:
    print("OK")
else:
    print("NG")

Solution (Python):
k=int(input())
a,b=map(int,input().split())
s=0
for i in range(a,b+1):
    if i%k==0:
        s=1

if s==0:
    print('NG')
else:
    print('OK')

Solution (Python):
import sys
import math
from decimal import Decimal, ROUND_HALF_UP, ROUND_HALF_EVEN
from collections import deque
def I(): return int(sys.stdin.readline())
def MI(): return map(int, sys.stdin.readline().split())
def LI(): return list(map(int, sys.stdin.readline().split()))
def LI2(N): return [list(map(int, sys.stdin.readline().split())) for i in range(N)]
def S(): return sys.stdin.readline().rstrip()
def LS(): return sys.stdin.readline().split()
def LS2(N): return [sys.stdin.readline().split() for i in range(N)]
def FILL(i,h): return [i for j in range(h)]
def FILL2(i,h,w): return [FILL(i,w) for j in range(h)]
def FILL3(i,h,w,d): return [FILL2(i,w,d) for j in range(h)]
def FILL4(i,h,w,d,d2): return [FILL3(i,w,d,d2) for j in range(h)]
def sisha(num,digit): return Decimal(str(num)).quantize(Decimal(digit),rounding=ROUND_HALF_UP)

MOD = 1000000007
INF = float("inf")
sys.setrecursionlimit(10**5+10)
input = sys.stdin.readline

K = I()
A,B = MI()
for i in range(A,B+1):
    if i%K==0:
        print('OK')
        break
else:
    print('NG')

Solution (Python):
k = int(input())  
s, w = map(int, input().split())  

for i in range(s, w + 1):
    if i % k == 0:
        print('OK')
        exit()

print('NG')

Solution (Python):
k=int(input())
a,b=map(int,input().split())
for i in range(a,b+1):
  if i%k==0:
    print("OK")
    break
else:
  print("NG")

Solution (Python):
K = int(input())
A, B = map(int, input().split())

import sys 

for i in range(1, 1001):
    tmp = i * K
    if A <= tmp <= B:
        print("OK")
        sys.exit(0)
print("NG")

Solution (Python):
K = int(input())
A, B = map(int, input().split())

flag = False

for i in range(A, B + 1):
    if i % K == 0:
        flag = True
if flag:
    print('OK')
else:
    print('NG')

Solution (Python):
k = int(input())
a,b = map(int,input().split())
l = []
for i in range(a,b+1):
    if i % k == 0:
        l.append(i)
if len(l) == 0:
    print("NG")
else:
    print("OK")

Solution (Python):
K = int(input())
A, B = map(int, input().split())

if B // K - A // K + int(A % K == 0) > 0:
    print('OK')
else:
    print('NG')

Solution (Python):
k=int(input())
a,b=map(int, input().split())
ans='OK'
for i in range(a,b+1):
    if i%k==0:
        ans='OK'
        break
    else:
        ans='NG'
print(ans)

Solution (Python):
def main():
    k=int(input())
    a,b=map(int,input().split())
    if a<= (b//k)*k <= b:
        print('OK')
    else:
        print('NG')
main()

Solution (Python):
k=int(input())
a,b=map(int, input().split())
flag=False
for i in range(a,b+1):
    if(i%k==0):
        flag=True
if(flag):
    print("OK")
else:
    print("NG")

Solution (Python):
k = int(input())
a, b = map(int, input().split())

flag = False
for i in range(a, b+1):
    if i % k == 0:
        flag = True
        break

if flag:
    print("OK")
else:
    print("NG")

Solution (Python):
K = int(input())
S,E = list(map(int, input().split()))
answer = "NG"
for i in range(S, E+1):
    if i % K == 0:
        answer = "OK"
print(answer)

Solution (Python):
K = int(input())
A, B = map(int, input().split())
ok_flag = False
for i in range(A, B+1):
    if i % K == 0:
        ok_flag = True
        print("OK")
        break
if ok_flag == False:
    print("NG")

Solution (Python):
K = int(input())
A,B = map(int,input().split())

for i in range(A,B+1,1):
    if i % K == 0:
        print("OK")
        exit()

print("NG")

Solution (Python):
from math import factorial as fact
import math
import sys
import itertools
import numpy as np
from collections import Counter
import datetime



def input1():
	return int(input())


def input2():
	return map(int,input().split())


def input_array():
	return list(map(int,input().split()))

def keta(N):
	return len(str(N))


def input_daytime(input_time):
	time,distance=input_time.split()
	t=time.split(":")
	se=str(t[-1]).split(".")
	dt1 = datetime.timedelta(hours=int(t[0]),minutes=int(t[1]),seconds=int(se[0]),milliseconds=int(se[1]))
	return dt1

def combinations(n,r):
	return list(itertools.combinations(range(n),r))



def all_sets(num_list):
	subsets=[]
	for i in range(2,len(num_list) + 1):
		for c in combinations(num_list, i):
			subsets.append(c) 
	return subsets


def ch(x1):
	cf=[]
	for i in range(2,math.sqrt(x1)+1):
		if x1 % i==0:
			cf.append(i)
	return cf

def CountOneRoots(x,y):
	
	return fact(x+y)/fact(x)/fact(y)


def factorization(n):
	tmp=n
	count=0
	for i in range(2,int(n**0.5)+2):
		if tmp%i==0:
			cnt=0
			while tmp%i==0:
				cnt+=1
				tmp//=i
			count+=1
	if tmp!=1:
		count+=1

	return count
			




k = input1() 
a,b=input2()
flag=False
for i in range(a,b+1):
	if i % k==0:
		flag=True
		break

if flag:
	print("OK")
else:
	print("NG")

Solution (Python):


if __name__ == '__main__':
    

    k = int(input())
    a, b = map(int, input().split())

    

    

    flug = 1
    for i in range(1000):
        if (k * i >= a and k * i <= b):
            flug = 0
            break
    

    if (flug == 1):
        print("NG")
    else:
        print("OK")

Solution (Python):
from sys import exit

k=int(input())
a,b=map(int,input().split())

for i in range(a,b+1):
	if i%k==0:
		print("OK")
		exit()
print("NG")

Solution (Python):

N = int(input())
A,B = map(int,input().split())
ans =0

for x in range(A,B+1):
    if x%N ==0:
        ans =1
        break
if ans ==1:
    print("OK")
else:
    print("NG")

Solution (Python):
k = int(input())
a, b = map(int, input().split())
if b % k == 0 or a % k == 0 or b // k > a // k:
    print('OK')
else:
    print('NG')

Solution (Python):
k=int(input())
a,b=map(int, input().split())
t=int(b/k)
if t*k >= a:
  print("OK")
else:
  print("NG")

Solution (Python):
k = int(input())
conditions = input().split(' ')
a = int(conditions[0])
b = int(conditions[1])

flag = False
for i in range(a, b+1):
    if i % k == 0:
        flag = True
        break

if flag:
    print('OK')
else:
    print('NG')

Solution (Python):
import sys
def input():
    return sys.stdin.readline().rstrip('\n')

def calc(K, A, B):
    for i in range(A, B + 1):
        if i % K == 0:
            return 'OK'
    return 'NG'


K = int(input())
(A, B) = tuple([int(s) for s in input().split()])
print(calc(K, A, B))

Solution (Python):
k=int(input())
a,b=map(int,input().split())

b-=b%k
if a<=b:
    print('OK')
else:
    print('NG')

Solution (Python):
k = int(input())
a,b = map(int,input().split())
for i in range(a,b+1):
    if i%k==0:
        exit(print("OK"))
print("NG")

Solution (Python):
import sys
k = int(input())
a, b = map(int, input().split())

for i in range(1000):
    if (k * i >= a and k * i <= b):
        print("OK")
        sys.exit()
    else:
        pass
print("NG")

Solution (Python):
import sys
rs = lambda: sys.stdin.readline().rstrip()
ri = lambda: int(rs())
rf = lambda: float(rs())
lrs = lambda: [_ for _ in rs().split()]
lri = lambda: [int(_) for _ in rs().split()]
lrf = lambda: [float(_) for _ in rs().split()]

K = ri()
A, B = lri()
ans = 'NG'
for i in range(1, 1000):
    if A <= i * K <= B:
        ans = 'OK'
print(ans)

Solution (Python):


K = int(input())
A, B = map(int, input().split())
ans = 'NG'

for i in range(A, B + 1):
    if i % K == 0:
        ans = 'OK'
        break

print(ans)

Solution (Python):
t=int(input())
a,b=map(int,input().split())
val=0
for i in range(a,b+1):
    if(i%t==0):
        val+=1
        break
if(val>0):
    print("OK")
else:
    print("NG")

Solution (Python):
from math import floor,ceil,sqrt,factorial,log
from collections import Counter, deque
from functools import reduce
import numpy as np
def S(): return input()
def I(): return int(input())
def MS(): return map(str,input().split())
def MI(): return map(int,input().split())
def FLI(): return [int(i) for i in input().split()]
def LS(): return list(MS())
def LI(): return list(MI())
def LLS(): return [list(map(str, l.split() )) for l in input()]
def LLI(): return [list(map(int, l.split() )) for l in input()]
def LLSN(n: int): return [LS() for _ in range(n)]
def LLIN(n: int): return [LI() for _ in range(n)]

n = I()

a,b = FLI()

for i in range(a, b+1):
    if i%n == 0:
        print("OK")
        exit()

print("NG")

Solution (Python):
K = int(input())
A, B = map(int, input().split())
left = (A + K - 1) // K
right = B // K
print("OK") if left <= right else print("NG")

Solution (Python):
k = int(input())
a,b = map(int, input().split())

flg = False
for i in range(a,b+1):
    if i%k == 0:
        flg = True
if flg:
    print('OK')
else:
    print('NG')

Solution (Python):
K = int(input())
A, B = map(lambda x: int(x), input().split(" "))

flag = False
for i in range(A, B+1):
    if i % K == 0:
        flag = True
        break

if flag:
    print("OK")
else:
    print("NG")

Solution (Python):

K = int(input())
A, B = map(int, input().split())
lst = [i % K for i in range(A, B + 1)]
if 0 in lst:
    print('OK')
else:
    print('NG')

Solution (Python):
k=int(input())
a,b=map(int,input().split())

ok=0
for i in range(a,b+1):
    if i%k==0:
        ok += 1
        print('OK')
        break
if ok==0:
    print('NG')

Solution (Python):


def main():
    k = int(input())
    a, b = map(int, input().split())

    res = False

    for i in range(a, b+1):
        if i % k == 0:
            print('OK')
            res = True
            break
    
    if res == False:
        print('NG')

if __name__ == '__main__':
    main()

Solution (Python):

k = int(input())
a, b = map(int, input().split())
ans = False
for i in range(a, b + 1):
    if i % k == 0:
        ans = True
print(["NG", "OK"][ans])

Solution (Python):
k=int(input())
a,b = map(int,input().split())

count = 0
for i in range(a, b+1):
    if i % k == 0:
        count += 1
if count == 0 :
    print('NG')
else:
    print('OK')

Solution (Python):
K=int(input())
A,B=map(int,input().split())
flag=0
for i in range(A,B+1):
    if i%K==0:
        flag=1

if flag==0:
    print("NG")
else:
    print("OK")

Solution (Python):
K = int(input())
a,b = map(int,(input().split()))
for i in range(a,b+1):
    if i%K == 0:
        print("OK")
        break
else:
    print("NG")

Solution (Python):
k = int(input())
a, b = map(int, input().split())

for i in range(a, b + 1):
    if i % k == 0:
        print("OK")
        exit()

print("NG")

Solution (Python):
def main():
    K = int(input())
    A, B = map(int, input().split())

    possible = False

    for i in range(A, B+1):
        if i % K == 0:
            possible = True

    if possible:
        print("OK")
    else:
        print("NG")
if __name__ == "__main__":
    main()

Solution (Python):
k = int(input())
a,b = map(int, input().split())
ans = 'NG'
for i in range(a,b+1):
    if i % k == 0:
        ans = 'OK'
        break
print(ans)

Solution (Python):
K = int(input())
A,B = map(int,input().split())
count = 0
for i in range(A,B+1):
  if(i % K == 0):
    count += 1
  else:
    pass
if(count != 0):
  print("OK")
else:
  print("NG")

Solution (Python):
K=int(input())
A,B=map(int,input().split())
ok = 0
for i in range(A,B+1):
  if ( i%K==0 ):
    ok = 1
if(ok==1):
  print("OK")
else:
  print("NG")

Solution (Python):
K = int(input())
A, B = map(int, input().split())

for i in range(A, B + 1):
    if i % K == 0:
        print('OK')
        exit()
print('NG')

Solution (Python):
x = int(input())

ab = [int(x) for x in input().split()]

if ab[1]-(ab[1]%x) >= ab[0]:
    print("OK")
else:
    print("NG")

Solution (Python):
K = int(input())
A, B = map(int, input().split())
ans = 'NG'

for i in range(A, B + 1):
    if i % K == 0:
        ans = 'OK'
        break

print(ans)

Solution (Python):
k = int(input())
a, b = map(int, input().split())
ok = False
for i in range(a, b + 1):
    if i % k == 0:
        ok = True
        break
if ok:
    print('OK')
else:
    print('NG')

Solution (Python):
K = int(input())
a,b = map(int, input().split())
for i in range(a,b+1):
    if i % K == 0:
        print("OK")
        exit()
print("NG")

Solution (Python):
def A():
    K = int(input())
    A, B = map(int, input().split())
    for n in range(A, B+1):
        if n%K == 0:
            print('OK')
            return
    print('NG')

A()

Solution (Python):
k = int(input())
a, b = map(int, input().split())

for i in range(a, b+1):
    if i % k == 0:
        print("OK")
        exit()
else:
    print("NG")

Solution (Python):
K = int(input())
A, B = map(int, input().split())

ans = "NG"

for i in range(A, B+1):
  if i % K == 0:
    ans = "OK"

print(ans)

Solution (Python):


K = int(input())
A,B = map(int, input().split())
cnt = 0
for i in range(A,B+1):

    if i % K == 0:
        cnt += 1
if cnt == 0:
    print("NG")
else:
    print("OK")

Solution (Python):
k=int(input())
a,b=map(int,input().split())
cnt = 0
for i in range(a,b+1):
  if i%k==0:
    cnt+=1
    print("OK")
    break;
if cnt == 0:
  print("NG")

Solution (Python):
k=int(input())
a,b=list(map(int,input().split()))
ans=False
for i in range(a,b+1):
    if i%k==0:
        ans=True
        break
print('OK') if ans==True else print('NG')

Solution (Python):

MOD = 10 ** 9 + 7
INFI = 10**10

import math

import itertools
import heapq


import copy
from functools import lru_cache

def sosuhante(n):
    for k in range(2, int(math.sqrt(n))+1):
        if n% k ==0:
            return False
    return True
def cmb(n, r):
    if n - r < r: r = n - r
    if r == 0: return 1
    if r == 1: return n

    numerator = [n - r + k + 1 for k in range(r)]
    denominator = [k + 1 for k in range(r)]

    for p in range(2,r+1):
        pivot = denominator[p - 1]
        if pivot > 1:
            offset = (n - r) % p
            for k in range(p-1,r,p):
                numerator[k - offset] /= pivot
                denominator[k] /= pivot

    result = 1
    for k in range(r):
        if numerator[k] > 1:
            result *= int(numerator[k])

    return result

def kingaku(a,b,n):
    keta=len(str(n))
    return a*n+b*keta

def my_index(l, x, default=False):
    if x in l:
        return l.index(x)
    else:
        return default




def ret(a):
    c=[None]*(len(a)-1)
    if len(a)==1:
        return a[0]
    elif len(a)==0:
        return 0
    for i in range(1,len(a)):
        c[i-1]=abs(a[i]-a[i-1])
    return ret(c)


def main():
    k=int(input())
    a,b=map(int,input().split())
    ans="NG"
    for i in range(a,b+1):
        if i%k==0:
            ans="OK"
            break
    print(ans)




if __name__ == "__main__":

    main()

Solution (Python):

K = int(input())
[A,B] = list(map(int,input().split()))

flag=0
for i in range(A,B+1):
        if i%K==0:
            flag=1

if flag==1:
    print('OK')
else:
    print('NG')

Solution (Python):
K=int(input())
A,B=map(int,input().split())
for i in range(A,B+1):
    if i%K==0:
        print("OK");exit()
print("NG")

Solution (Python):


def run():
    K = int(input())
    A,B = map(int, input().split())
    if B // K - (A-1) // K >= 1:
        print('OK')
    else:
        print('NG')


if __name__ == "__main__":
    run()

Solution (Python):
n = int(input())
a,b = map(int, input().split())
x = a%n
if x == 0 or a+(n-x) <= b:
    print('OK')
else:
    print('NG')

Solution (Python):

k= int(input())
a, b = map(int, input().split())
p = 0
for i in range(a, b+1):
    if i % k == 0:
        print("OK")
        p = 1
        break
if p == 0:
    print("NG")

Solution (Python):
k=int(input())
a,b=map(int,input().split())

if a % k ==0 or b % k == 0:
    print("OK")
elif a//k == b//k:
    print("NG")
else:
    print("OK")

Solution (Python):
K=int(input())
A,B=map(int,input().split())
for i in range(A,B+1):
  if i%K==0:
    print("OK")
    break
  if i==B:
    print("NG")

Solution (Python):
K = int(input())
A,B = map(int,input().split())
flag = False
for i in range(A,B+1):
  if i % K == 0:
    flag = True
    break
if flag:
  print("OK")
  
else:
  print("NG")

Solution (Python):
import sys

stdin = sys.stdin
inf = 1 << 60
mod = 1000000007

ni      = lambda: int(ns())
nin     = lambda y: [ni() for _ in range(y)]
na      = lambda: list(map(int, stdin.readline().split()))
nan     = lambda y: [na() for _ in range(y)]
nf      = lambda: float(ns())
nfn     = lambda y: [nf() for _ in range(y)]
nfa     = lambda: list(map(float, stdin.readline().split()))
nfan    = lambda y: [nfa() for _ in range(y)]
ns      = lambda: stdin.readline().rstrip()
nsn     = lambda y: [ns() for _ in range(y)]
ncl     = lambda y: [list(ns()) for _ in range(y)]
nas     = lambda: stdin.readline().split()

k = ni()
a, b = na()

flag = False
i = a
while i <= b:
    if i % k == 0:
        flag = True
    i += 1

print("OK" if flag else "NG")

Solution (Python):
import math
a=int(input())
n,k=map(int,input().split())

for i in range(n,k+1):
    if i%a==0:
        print("OK")
        exit()
print("NG")