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):
K = int(input())
A, B = map(int, input().split())
result = 'NG'
for i in range (A, B + 1):
    if i % K == 0:
        result = 'OK'
print(result)

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):
import sys

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

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

Solution (Python):
k= int(input())
x,y = map(int,input().split())
if 1<=x<=y<=1000 and 1<=k<=1000:
    pass



    if x%k>>0 :
        if x<= (x//k+1)*k <=y :
            print('OK')
        else:
            print('NG')
    else:
        print('OK')

else:
    print('NG')

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

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

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

Solution (Python):
import numpy as np
s= int(input())
List = list(map(int, input().split()))
array = list()
for i in range(List[0],List[1]+1):
    if s == 1:
        array.append("OK")
        break
    if i % s == 0:
        array.append("OK")
        break
if ('OK' in array):
    print("OK")
else:
    print("NG")

Solution (Python):
K = input().strip()
K_int = int(K)

A, B = input().strip().split(" ")
A_int = int(A)
B_int = int(B)

possible = False

for i in range(A_int, B_int + 1):
    if i % K_int == 0:
        possible = True
        break

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

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

tmp = a

if a % k == 0 or b % k == 0:
  print("OK")
else:
  for i in range(a,b):
    if i % k == 0:
      if i <= b:
        print("OK")
        break
      else:
        print("NG")
        break
  else:
    print("NG")

Solution (Python):
import collections

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

X = []

for i in range(B - A + 1):
    m = A + i
    n = m % K

    X.append(n)

dict = collections.Counter(X)
l = dict[0]

if l > 0:
    print('OK')
else:
    print('NG')

Solution (Python):
import sys
sys.setrecursionlimit(300000)

def I(): return int(sys.stdin.readline())
def MI(): return map(int, sys.stdin.readline().split())
def LMI(): return list(map(int, sys.stdin.readline().split()))
MOD = 10 ** 9 + 7
INF = float('inf')


K = I()
A, B = MI()

for i in range(A, B + 1):
    if i % K == 0:
        print('OK')
        exit(0)
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()

print("NG")

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

for cnt in range(int(b)):
    if cnt+1 >= int(a):
       

        if int(cnt+1)% int(k) == 0 or int(k) == 1:
            print("OK")
            exit()
print("NG")

Solution (Python):
import sys
readline = sys.stdin.readline

K = int(readline())
A, B = map(int, readline().split())
ans = 'NG'
for x in range(A, B+1):
    if x%K == 0:
        ans = 'OK'
print(ans)

Solution (Python):


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

ans = 'NG'

h = b-a+1

for i in range(h):
    p = a + i
    if p % k == 0:
        ans = 'OK'

print(ans)

Solution (Python):
import numpy as np
a = int(input())
b,c=map(int,input().split())
d = np.arange(a,1001,a)
f = np.arange(b,c+1)
d_set=set(d)
f_set=set(f)

g_set=d_set&f_set 

g=list(g_set)
if len(g) == 0:
    print('NG')
else:
    print('OK')

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

ans = "NG"
if k == 1:
    ans = "OK"
elif k >1000:
    ans = "NG"
else:
    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 Num in range(A,B+1):
    if Num%K ==0:
        count+=1
if count !=0:
    print("OK")
else:
    print("NG")

Solution (Python):
import sys
input = sys.stdin.readline

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 = [int(n) for n in 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())
def ok_ng():
    for i in range(a, b+1):
        if i % k == 0:
            return "OK"
    else:
        return "NG"
print(ok_ng())

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

for i in range(1, 1001):
    if a <= i * k <= b:
        cnt += 1

print("OK" if cnt > 0 else "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=(int(x) for x in 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())
n = list(map(int,input().split()))
a = n[0]
b = n[1]

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

if check == 0:
    print("NG")

Solution (Python):
def tom(x, y, k):
  n = x
  while n >= x and n <= b:
    if n % k == 0:
      return 'OK'
    n += 1
  return 'NG'
k = int(input())
a, b = map(int, input().split())
result = tom(a, b, k)
print(result)

Solution (Python):
k = int(input())
num = list(map(int, input().split()))
A,B = num[0],num[1]
for i in range(1,1000):
    if A <= k*i <= B:
        print("OK")
        break
    elif B < k*i:
        print("NG")
        break

Solution (Python):
import sys
K = int(sys.stdin.readline())
A, B = map(int, sys.stdin.readline().split())
print("OK" if (A <= (B // K) * K) else "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())
C=B-A
if C>=K-1:
    print("OK")
elif A%K==0:
    print("OK")
elif B%K==0:
    print("OK")
elif A//K != B//K:
    print("OK")
else:
    print("NG")

Solution (Python):
K = int(input())
A, B = map(int, input().split())
b = False
bai = K
counter = 1
while bai <= B:
    if A <= bai <= B:
        b = True
        break
    counter += 1
    bai = K*counter
if b:
    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(0)

print("NG")

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

if a == b:
    if a % n == 0:
        print('OK')
    else:
        print('NG')
elif a % n == 0:
    print('OK')
else:
    while a < b:
        a += 1
        if a % n == 0:
            print('OK')
            break
        elif a == b:
            print("NG")

Solution (Python):
a=int(input())
b,c=input().split()
d=0
while True:
    if (int(b))<=(a*d)<=(int(c)):
        print("OK")
        break
    elif (int(c))<(a*d):
        print("NG")
        break
    d+=1

Solution (Python):
K = int(input())
a,b = list(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())

A_d = A//K
B_d = B//K

if (B_d-1)*K >= A or (A_d+1)*K <= B or A%K == 0 or B%K == 0:
    print("OK")

else:
    print("NG")

Solution (Python):
K = int(input())
A, B = map(int,input().split())
number = A
count = 0
while(1):
 if(number%K == 0):
  count +=1
 number += 1  
 if(number > B):
  if(count >0):
    print("OK")
  else:
    print("NG")
  break;

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

Solution (Python):
a = int(input())
b = input().split()
b[0] = int(b[0])
b[1] = int(b[1])
A = b[0] / a
B = b[1] / a
C = B - A
if a == 1:
    print('OK')
elif b[1]%a == 0:
    print('OK')
elif b[0]%a == 0:
    print('OK')
elif C >= 1:
    print('OK')
elif (b[1]//a)*a >= b[0]:
    print('OK')
else:
    print('NG')

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

is_ok = 0

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

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

if k == a:
    flag = 1
elif k < a:
    if a % k == 0 :
        flag = 1
    elif (int(a / k)+1) * k <= b:
        flag = 1
elif a < k:
    if k <= b:
        flag = 1

  
if flag:
  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())
if a == b and a%k == 0:
    print("OK")
elif a%k == 0 or b%k == 0:
    print("OK")
elif a != b and a//k != b//k:
    print("OK")
else:
    print("NG")

Solution (Python):
K=int(input())
A,B=map(int,input().split())
i=1
ok=0
while i*K <= B and ok!=1:
    if A <= i*K <= B:
        print("OK")
        ok=1
    i=i+1
if ok!=1:
    print("NG")

Solution (Python):

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

yn=""
for i in range(a,b+1):
    if i%k==0:
        yn="OK"
if yn=="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')
        break
else:
    print('NG')

Solution (Python):
k=int(input())
a,b=map(int,input().split())
aa=a//k
bb=b//k
ax=a%k
bx=b%k
if (aa==bb and (ax==0 or bx==0)) or aa!=bb or k==1:
	print("OK")
else:
	print("NG")

Solution (Python):
k=int(input())
a,b=map(int,input().split())
d=0
v=0
for i in range(1001):
    d=k*i
    if d>=a and d<=b:
        v+=1

if v>=1:
    print("OK")
else:
    print("NG")

Solution (Python):

K = int(input())

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



if A%K != 0:
  if A-(A%K)+K <= B:
    print("OK")
  else:
    print("NG")
else:
    print("OK")

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

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

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

flag = False
for i in range(a, b+1):
    if i % k == 0:
        flag = True
        break
    else:
        continue
if flag is True:
    print("OK")
else:
    print("NG")

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

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

b = B % K
w = B - A

if w - b >= 0:
    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(0)

print('NG')

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

flag = False
for i in range(K, 1001, K):
    if A <= i <= B:
        flag = True
        break

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

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:
    count+=0

if count >0:
  print('OK')
else:
  print('NG')

Solution (Python):
N = int(input())
A,B = list(map(int, input().split()))
takahashi = list(range(A, B+1))
d_list=[]
for i in takahashi :
    if i % N == 0:
        d_list.append(1)
    else:
        d_list.append(0)
if 1 in d_list:
    print("OK")
else:
    print("NG")

Solution (Python):

def main():
    K = int(input())
    A, B = map(int, input().split())
    m = B // K
    out = 'NG'
    for i in range(1, m+1):
        ans = i * K
        if A <= ans <= B:
            out = 'OK'
    print(out)
main()

Solution (Python):
k=int(input())
a,b=map(int,input().split())
if(b%k>abs(b-a)): print("NG")
else: print("OK")

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())
list = input().split()

if int(list[0])//k != int(list[1])//k:
  print("OK")
elif int(list[0])%k == 0:
  print("OK")
else:
  print("NG")

Solution (Python):
k=int(input())
a,b=map(int,input().split())
t=a
while t<b+1:
    if t%k==0:
        print("OK")
        exit()
    t+=1
print("NG")

Solution (Python):
K = int(input())
A, B = list(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());

if (a // k) * k == a or (a // k + 1) * k <= b:
  print("OK");
else:
  print("NG");

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

i=A
length = B-A+1
judge = 0

for _ in range(length):
    if(i%K==0):
        judge = 1
        break

    i += 1
    
if judge==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' )
        quit()
else:
    print( 'NG' )

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

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


if k*(i)>=a and k*(i)<=b:
        print("OK")
elif k*(i+1)>=a and k*(i+1)<=b:
        print("OK")
        
else:
    print("NG")

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

c = 0

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

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

for i in range(1000):
  if A <= K*(i+1) <= B:
    print('OK')
    break
else:
  print('NG')

Solution (Python):
k = int(input())
l, m = map(int, input().split())

o = (((m+(k-m%k))/k)-1)*k

if (l <= o <= m):
    print("OK")
else:
    print("NG")

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

for i in range(b-a+1):
  if a % k != 0:
    a += 1
  else:
    print('OK')
    break
if a == b+1 and b%k != 0:
  print('NG')

Solution (Python):
import sys
import math
from collections import defaultdict
from bisect import bisect_left, bisect_right

sys.setrecursionlimit(10**7)
def input():
    return sys.stdin.readline()[:-1]

mod = 10**9 + 7

def I(): return int(input())
def LI(): return list(map(int, input().split()))
def LIR(row,col):
    if row <= 0:
        return [[] for _ in range(col)]
    elif col == 1:
        return [I() for _ in range(row)]
    else:
        read_all = [LI() for _ in range(row)]
        return map(list, zip(*read_all))



K = I()
A,B = LI()

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())
AB = input()
ABB = AB.split()
A = int(ABB[0])
B = int(ABB[1])
C = 0

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

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

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

Solution (Python):
K = int(input())
A, B = map(int, input().split())
k = 0
while k <= B:
    if A <= k <= B:
        print('OK')
        exit()
    k += K
print('NG')

Solution (Python):
K = int(input())
A, B = map(int, input().split())
List = []
x = 0
cnt = 1
state = 0
for n in range((B-A)+1):
    List.append(A + n)

for i in range(len(List)):
    if List[i]%K == 0:
        print('OK')
        state = 1
        break

if state == 0:
    print('NG')

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

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

if x == 0:
    print("NG")

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


ps = int(A / K)
pa = A % K
qs = int(B / K)
qa = B % K

if A==B:
	if pa==0:
		print("OK")
	else:
		print("NG")
else:
	if qs-ps>0:
		print("OK")
	else:
		if pa==0 or qa ==0:
			print("OK")
		else:
			print("NG")

Solution (Python):
inp = [input() for i in range(2)]
uu = int(float(inp[0]))
K = int(uu)
A,B = inp[1].split()
A,B = int(float(A)),int(float(B))
c,bbb = 0,0
if 1<= A <= B <= 1000 and 1<= K <= 1000:
  for h in range(A,B,1):
    c = h % K
    if c == 0:
      bbb += 1
  if bbb > 0:
    print('OK')
  elif K == 1:
    print('OK')
  elif K ==A or K ==B:
    print('OK')
  elif A % K == 0 or B % K == 0:
    print('OK')
  else:
    print('NG')

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

for i in range(1000):
    if a<= k*i <=b :
        print("OK")
        exit()
print("NG")

Solution (Python):
times = int(input())
range_distance=input().split()
ini=int(range_distance[0])
end=int(range_distance[1])

dev = end - ini 
num = 0
cnt=0

for i in range(dev+1):
    num = ini + i
    if num % times ==0:
        cnt +=1
        break

if cnt >0:
    print("OK")              
else:
    print("NG")

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

for i in range(b+1):
    s = k*i
    if a <= s and s <= b:
        print('OK')
        break
    elif s > b:
        print('NG')
        break

Solution (Python):
import sys
K = int(input())
A, B = map(int, input().split())
for i in range(1,1000):
    t=i*K
    if t>=A and t<=B:
        print("OK")
        sys.exit()
print("NG")

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

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

if B // K != A // K:
    print('OK')
elif B % K == 0 or A % K == 0:
    print('OK')
else:
    print('NG')

Solution (Python):
K=int(input())
A,B=map(int,input().split())
for i in range(1001):
  s=i*K
  if A<=s and s<=B:
    print("OK")
    break
  if 1000<s:
    print("NG")
    break

Solution (Python):
def iin(): return int(input())
def iln(): return list(map(int, input().split()))

K = iin()
A, B = iln()

curr_num = A
while curr_num % K != 0:
    curr_num += 1

if A <= curr_num <= B:
    print("OK")
else:
    print("NG")

Solution (Python):
def main():
  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")
 
main()

Solution (Python):
A = int(input())
B, C = map(int,input().split())
flag = 1

for i in range(B, C+1):
  if i % A == 0:
    flag = 0
    print("OK")
    break

if flag==1:
  print("NG")

Solution (Python):
import math
import sys

stdin = sys.stdin

ns = lambda: stdin.readline().rstrip()
ni = lambda: int(stdin.readline().rstrip())
nm = lambda: map(int, stdin.readline().split())
nl = lambda: list(map(int, stdin.readline().split()))
mod = 10**9 + 7 
sys.setrecursionlimit(1000010)


K = ni()
A,B = nm()
if A % K == 0:
    print('OK')
    exit(0)
if B // K != A //K :
    print('OK')
    exit(0)
print('NG')

Solution (Python):


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

ans="NG"

for i in range(1,1000):
    if K*i >= A and K*i <= B: 
        ans="OK"
        break

print(ans)

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

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())
num =A
while A <= num <= B:   
    if num % K == 0:
        x="OK"
        break
    else:
        x="NG"
        num +=1
print(x)

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(int,input().split())
if a%k==0 or b%k==0:
    print('OK')
elif b-a < k and a%k <= b%k:
    print('NG')
else:
    print('OK')

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 = [int(i) for i in input().split()]

min_multi = int((A / K) + 1)
noKiri = K * min_multi
Kiri = K * ( min_multi - 1 )
if ( A <= noKiri <= B ) or (A <= Kiri <= B) :
  print('OK')
else :
  print('NG')

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

if k == 1 :
    print('OK')
    exit(0)
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(" "))
n = int(A/K)
m = int(B/K)
if K ==1:
  print("OK")
else:
  if n == m and n == A/K:
    print('OK')
  elif n == m:
    print('NG')
  else:
    print('OK')

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

q1, mod1 = divmod(A, K)
q2, mod2 = divmod(B, K)

if mod1 == 0:
    print("OK")
elif mod2 == 0:
    print("OK")
elif A + K - mod1 <= B:
    print("OK")
else:
    print("NG")

Solution (Python):
k = int(input())
a, b = map(int, input().split())
while a%k != 0:
    a = a+1

if a<=b:
    print("OK")
else:
    print("NG")

Solution (Python):
k = int(input())
list = list(map(int,input().split()))
a=list[0]
b=list[1]

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())
ans = 'NG'
for i in range(a, b+1):
    if i % k == 0:
        ans = 'OK'
print(ans)

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

k = (A+(K-1))//K

if K*k <= B:
	print('OK')
else:
	print('NG')

Solution (Python):



import math

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

j_a = math.floor(float(A)/float(K))
j_b = math.floor(float(B)/float(K))

if(float(A)%float(K) ==0):
    print('OK')
elif(float(B)%float(K) ==0):
    print('OK')
elif(j_b-j_a >= 1):
    print('OK')
    
else:
    print('NG')

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

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

Solution (Python):



def inp():
    return(int(input().rstrip()))
def inlt():
    return(list(map(int,input().rstrip().split())))
def insr():
    s = input().rstrip()
    return(s[:len(s) - 1])
def invr():
    return(map(int,input().rstrip().split()))

k = inp()
a,b = invr()

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

Solution (Python):
K = int(input())
A,B = map(int, input().split())
import  math
C = math.ceil(A/K)
if C*K <=B:
    print("OK")
else:
    print("NG")

Solution (Python):
K = int(input())
A,B = map(int, input().split())
print("NG" if all([i%K for i in range(A,B+1)]) else "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):
n = int(input())
a, b = map(int, input().split())
k = 1
while True:
    if a <= n*k <= b:
        print("OK")
        exit()
    elif n*k > b:
        print("NG")
        exit()
    else:
        k += 1

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

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

N = A // K

flag = False
for i in range(N, N+1000):
    v = K * i
    if (A <= v) and (v <= B):
        print("OK")
        flag = True
        break
        
if not flag:
    print("NG")

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

if a==1:
    print('OK')
else:
    c=0
    b=m-n
    for i in range(b+1):
        if (m-i)%a==0:
            c+=1
            break

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

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

x=0

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

if x==0:
	print("NG")

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

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())
a = 0
for i in range(A,B+1):
    if i%K==0:
        a = 1
if a==1:
    print('OK')
if a==0:
    print('NG')

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

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

Solution (Python):
def main():
  k = int(input())
  a, b = map(int,input().split())
  if a%k==0 or b%k==0 or b-a >= abs(k-a%k):
    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(1, B//K+1):
  if K*i>=A and K*i<=B:
    ans = 'OK'
    break

print(ans)

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

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

ans=0

for i in range(int(a/k-1),math.ceil((b/k)+1)):
  if(k*i>=a):
    if(k*i<=b):
      ans=1
      break
if(k==1):
  ans=1

if(ans==0):
  print("NG")
if(ans==1):
  print("OK")

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

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

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

Solution (Python):
import sys
sys.setrecursionlimit(1 << 25)
read = sys.stdin.readline
ra = range
enu = enumerate


def read_ints():
    return list(map(int, read().split()))


def read_a_int():
    return int(read())


def read_tuple(H):
    '''
    H is number of rows
    '''
    ret = []
    for _ in range(H):
        ret.append(tuple(map(int, read().split())))
    return ret


def read_col(H):
    '''
    H is number of rows
    A列、B列が与えられるようなとき
    ex1)A,B=read_col(H)    ex2) A,=read_col(H) 
    '''
    ret = []
    for _ in range(H):
        ret.append(list(map(int, read().split())))
    return tuple(map(list, zip(*ret)))


def read_matrix(H):
    '''
    H is number of rows
    '''
    ret = []
    for _ in range(H):
        ret.append(list(map(int, read().split())))
    return ret
    


MOD = 10**9 + 7
INF = 2**31  

from collections import defaultdict, Counter, deque
from operator import itemgetter
from itertools import product, permutations, combinations
from bisect import bisect_left, bisect_right  
from math import gcd

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

Solution (Python):
N = int(input())
A=[int(x) for x in input().split()]
k=0
if N==1:
    print("OK")
else:
     if A[0]//int(N) == A[1]//int(N)  and A[0]%int(N)!=0  and A[1]%int(N)!=0:
        print("NG")
     else:
         print("OK")

Solution (Python):
k = int(input())
arr = list(map(int, input().split()))

a = arr[0]
b = arr[1]

count=0

now_max = arr[0]

for num in range(a,b+1):
    if num%k==0:
        print('OK')
        break
    elif num==b and num%k!=0:
        print('NG')

Solution (Python):
k = int(input())
a,b = map(int,input().split())
c = b - a
lis = []
if k == 1:
    print("OK")
elif b - a >= k:
    print("OK")
else:
    for i in range(c+1):
        d = (a + i)% k
        lis.append(d)
    if lis.count(0) == 0:
        print("NG")
    else:
        print("OK")

Solution (Python):
import sys
input = sys.stdin.readline


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

c = b//k

if k == 1:
    print("OK")
else:
    if c * k >=a:
        print("OK")
    else:
        print("NG")

Solution (Python):
k=int(input())
a,b=map(int,input().split())
r=b-a
d=k-(a%k)
if d==k:
    print("OK")
elif r>=d:
    print("OK")
else :
    print("NG")

Solution (Python):
k = int(input())
a, b = [int(x) for x in input().split()]
result = False
check = [x*k for x in range(0, 1000)]
for i in check:
    if (i >= a and i <= b):
        result = True
    else:
        continue

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

Solution (Python):
k = int(input())
n, m = map(int, input().split())

if n % k == 0 or m % k == 0:
    print("OK")
    exit()

l = n // k + 1
if l * k <= m:
    print("OK")
else:
    print("NG")

Solution (Python):
from sys import stdin

def main():

    input = stdin.readline

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

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

    
if __name__ == "__main__":
    main()

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

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())
a=0
for i in range(1,1002):
  if A<=K*i<=B:
    print("OK")
    break
  a=i
if a==1001:
  print("NG")

Solution (Python):
K = int(input())
score = input().split()
s1 = int(score[0])
s2 = int(score[1])
if ( s1 % K ) == 0:
		print('OK')
elif ( s2 % K ) == 0:
		print('OK')
elif ( s1 // K ) < ( s2 // K ):
		print('OK')
else:
		print('NG')