qyliang/CodeNanoFix huggingface dataset:
Buggy code:
K = int(input())

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

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

Fixed code:
K = int(input())
 
A,B=map(int,input().split())
 
if (int(B/K) - int((A-1)/K) ) >=1 :
    print('OK')
else :
    print('NG')
Buggy code:
k = int(input())
a, b = list(map(int, input().split()))
flg = "NG"
for i in range(a, b + 1):
    if i % a == 0:
        flg = "OK"
        break

print(flg)

Fixed code:
k = int(input())
a, b = list(map(int, input().split()))
flg = "NG"
for i in range(a, b + 1):

    if i >= k and i % k == 0:
        flg = "OK"
        break

print(flg)
Buggy code:
K = int(input())
A, B = map(int, input().split())

if B - (B % K) > A:
    print('OK')
else:
    print('NG')


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

if K == 1:
    print('OK')
elif B - (B % K) >= A:
    print('OK')
else:
    print('NG')
Buggy code:
n=int(input())
a,b=map(int,input().split())

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


Fixed code:
n=int(input())
a,b=map(int,input().split())
flag=0
for i in range(a,b+1):
    if i%n==0:
        flag=1
if flag==1:
    print("OK")
else:
    print("NG")
Buggy code:
def main():
  K = int(input())
  A, B = map(int, input().split())

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

if __name__ == '__main__':
  main()


Fixed code:
def main():
  K = int(input())
  A, B = map(int, input().split())

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

if __name__ == '__main__':
  main()
Buggy code:
K = int(input())
A,B = map(int,input().split())

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


Fixed code:
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")
Buggy code:
k=int(input())
a,b= map(int, input().split())
q=0

for i in range(1,1000):
  if a<=k*i and k*i<=b:
    print('OK')
    q=1
    

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

Fixed code:
k=int(input())
a,b= map(int, input().split())
q=0

for i in range(1,1000):
  if a<=k*i and k*i<=b:
    print('OK')
    q=1
    break

if q==0:
  print('NG')
Buggy code:
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")
else:
  print("NG")

Fixed code:
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")
Buggy code:
K=int(input())
M,N = map(int,input().rstrip().split(" ")) 
#print(K,M,N)
for number in range(M,N+1):
    if number%K==0:
        ans=True
if ans:
    print("YES")
else:
    print("NG")

Fixed code:
K=int(input())
ans = False
M,N = map(int,input().rstrip().split(" ")) 
#print(K,M,N)
for number in range(M,N+1):
    if number%K==0:
        ans = True
if ans:
    print("OK")
else:
    print("NG")
Buggy code:
def main():
  x = int(input())
  a, b = map(int, input().split())
  
  for i in range(a, b+1):
    if i % x == 0:
      print('OK')
      return
  
  print('No')
    
      
  
main()

Fixed code:
def main():
  x = int(input())
  a, b = map(int, input().split())
  
  for i in range(a, b+1):
    if i % x == 0:
      print('OK')
      return
  
  print('NG')
    
      
  
main()
Buggy code:
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")
else:
  print("NG")

Fixed code:
K=int(input())
A,B=map(int,input().split())
a=0
for i in range(A,B+1):
  if i%K==0:
    a+=1
    break
if a==1:
  print("OK")
else:
  print("NG")
Buggy code:
from collections import defaultdict

import sys
sys.setrecursionlimit(10**6)
ii = lambda: int(input())
mis = lambda: map(int,input().split())
lmis = lambda: list(mis())
INF = float('inf')

def main():
    k=ii()
    a,b=mis()
    x=b//k-a//k
    print('OK' if x>0 else 'NG')

if __name__ == "__main__":
    main()

Fixed code:
from collections import defaultdict

import sys
sys.setrecursionlimit(10**6)
ii = lambda: int(input())
mis = lambda: map(int,input().split())
lmis = lambda: list(mis())
INF = float('inf')

def main():
    k=ii()
    a,b=mis()
    x=b//k-(a-1)//k
    print('OK' if x>0 else 'NG')

if __name__ == "__main__":
    main()
Buggy code:
k = int(input())
a, b=map(int,input().split())
c = 0
Lists = list(range(a, b+1))
for i in Lists:
    if i % k == 0:
        print("OK")
        c = 1
if c == 0:
    print("NG")


Fixed code:
k = int(input())
a, b = map(int,input().split())
c = 0
Lists = list(range(a, b+1))
for i in Lists:
    if i % k == 0:
        print("OK")
        c += 1
        break
if c == 0:
    print("NG")
Buggy code:
k = int(input())
a ,b = map(int, input().split())
flag= False
for i in range(a,b):
  if i%k is 0:
    flag= True
    break

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

Fixed code:
k = int(input())
a ,b = map(int, input().split())
flag= False
for i in range(a,b+1):
  if i%k is 0:
    flag= True
    break

if flag is True:
  print("OK")
else:
  print("NG")
Buggy code:
K=int(input())
a,b=map(int,input().split())
flag = 0
for i in range(a,b+1):
    if i%K == 0:
        flag = 1
        break
print('OK' if flag==1 else 'NO')

Fixed code:
K=int(input())
a,b=map(int,input().split())
flag = 0
for i in range(a,b+1):
    if i%K == 0:
        flag = 1
        break
print('OK' if flag==1 else 'NG')
Buggy code:
k = int(input())
a, b = map(int, input().split())
p = a % k
q = k - p
if (p == 0) or ((a + p) <= b):
    print('OK')
else:
    print('NG')


Fixed code:
k = int(input())
a, b = map(int, input().split())
p = a % k
q = k - p
if (p == 0) or ((a + q) <= b):
    print('OK')
else:
    print('NG')
Buggy code:
k = int(input())
a, b = map(int,input().split())

res_k = (a//k + 1)*k

if res_k >= a and res_k <= b:
    print('OK')
else:
    print('NG')

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

if a%k == 0:
    res_k = a
else:
    res_k = (a//k + 1)*k

if (res_k >= a) and (res_k <= b):
    print('OK')
else:
    print('NG')
Buggy code:
a = int(input())
b, c = map(int, input().split())
for i in range(b, c + 1):
  if i % a == 0:
    print("OK")
    break
  else: 
    print("NG")
    break

Fixed code:
a = int(input())
b, c = map(int, input().split())
flag = 0
for i in range(b, c + 1):
  if i % a == 0:
    flag = 1
    break

if flag == 1: print("OK")
else: print("NG")
Buggy code:
K = int(input())
A, B = map(int, input().split())

if A % K == 0 or B//K != A//K:
    print("OK")
else:
    print("NO")


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

if A % K == 0 or B//K != A//K:
    print("OK")
else:
    print("NG")
Buggy code:
k = int(input())
a,b = map(int,input().split())
for i in range(a-1,b+1):
  if i % k == 0:
    ans = 'OK'
    break
  else:
    ans = 'NG'
print(ans)


Fixed code:
k=int(input())
a,b=map(int,input().split())
ans=0
for i in range(a,b+1):
  if i%k==0:
    ans=1
  else:pass
if ans==1:
  print('OK')
else:
  print('NG')
Buggy code:
K = int(input())
A,B = map(int,input().split(" "))
n=0
s='NG'
while():
    n+=k
    if A<=n and n<=B:
        s='OK'
print(s)

Fixed code:
K = int(input())
A,B = map(int,input().split(" "))
n=0
s='NG'
while(n<=B):
    n+=K
    if A<=n and n<=B:
        s='OK'
print(s)
Buggy code:
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("No")
    break

Fixed code:
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
Buggy code:
import sys
K=int(input())
A,B=map(int,input().split())
for i in range(A,B):
  if i%K==0:
    print("OK")
    sys.exit()
print("NG")

Fixed code:
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")
Buggy code:
k = int(input())
a,b = map (int, input().split())
res = "NG"
for i in range(a,b+1):
  if((i%k==0):
     res="OK"
     break
print(res)

Fixed code:
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')
Buggy code:
k = int(input())
a,b = map(int,input().split())
c = b - a
print(c)
lis = []
if k == 1:
    print("OK")
else:
    for i in range(c):
        lis.append(a + i % k)
    if lis.count(0) == 0:
        print("OK")
    else:
        print("NG")

Fixed code:
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")
Buggy code:
k = int(input()) 
a,b= map(int,input().split())
ans = "NG"
L = [i in i for range(1,1001) if i%k==0]
for j in range(a,b+1):
    if j in L:
        ans="OK"
print(ans)

Fixed code:
k = int(input()) 
a,b= map(int,input().split())
ans = "NG"
L = []
for l in range(1,1001):
    if l%k == 0:
        L.append(l)
for j in range(a,b+1):
    if j in L:
        ans="OK"
print(ans)
Buggy code:
a = int(input())

low, hi = map(int, input().split())

start = a * low//a

boolean = False

while not (start > hi):
  if lo <= start <= hi: 
    boolean = True
    break

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

Fixed code:
a = int(input())

low, hi = map(int, input().split())

start = a * int(low//a)

boolean = False

while not (start > hi):
  if low <= start <= hi: 
    boolean = True
    break
  start += a

if boolean: print("OK")
else: print("NG")
Buggy code:
N=int(input())
A,B=input().split(' ')
A=int(A)
B=int(B)
for i in range(1000):
  if A<i*N and i*N<B:
    print('OK')
    exit(0)
print('NG')

Fixed code:
N=int(input())
A,B=input().split(' ')
A=int(A)
B=int(B)
for i in range(1000):
  if A<=i*N and i*N<=B:
    print('OK')
    exit(0)
print('NG')
Buggy code:
k = int(input())
a, b = map(int,input().split())
flag = 0

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

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

Fixed code:
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")
Buggy code:
target = int(input())
range_d = [int(i) for i in input().split()]
min_d = range_d[0]
max_d = range_d[1]

flag = False
if max_d < target:
  flag = 
else:
  for i in range(min_d,max_d+1):
    if i%target == 0:
      flag = True
      break
	print('OK') if flag else print('NG')

Fixed code:
target = int(input())
range_d = [int(i) for i in input().split()]
min_d = range_d[0]
max_d = range_d[1]

flag = False
if max_d < target:
  print("NG")
else:
  for i in range(min_d,max_d+1):
    if i%target == 0:
      flag = True
      break
  print('OK') if flag else print('NG')
Buggy code:
k = int(input())
a, b = map(int, input().split())

c = 0

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

Fixed code:
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')
Buggy code:
K = int(input())
A,B= list(map(int, input().split()))
S = 0
while S<A:
    S += K
if S<B:
    print("OK")
else:
    print("NG")

Fixed code:
K = int(input())
A,B= list(map(int, input().split()))
S = 0
while S < A:
    S += K
if S <= B:
    print("OK")
else:
    print("NG")
Buggy code:
K = int(input())
A, B = map(int, input().split())

while K <= 1000:
  if K >= A and K <= B:
    print('OK')
    exit()
  K += K

print('NG')


Fixed code:
K = int(input())
A, B = map(int, input().split())
now = K
while now <= 1000:
  if now >= A and now <= B:
    print('OK')
    exit()
  now += K

print('NG')
Buggy code:
k = int(input())
a, b = map(int, input().split())
if a % k == 0 or b % k == 0:
    print("OK")
else:
    if b // k - a // k > 0:
        print("OK")
    else:
        print("NO")

Fixed code:
k = int(input())
a, b = map(int, input().split())
if a % k == 0 or b % k == 0:
    print("OK")
else:
    if b // k - a // k > 0:
        print("OK")
    else:
        print("NG")
Buggy code:
K=int(input())
A,B=map(int,input().split())
a=A//K
b=B//K
def f(x):
    return x//1
if f(b)-f(a)>=1:
    print("OK")
else:
    print("NG")


Fixed code:
K=int(input())
A,B=map(int,input().split())
a=A//K
b=B//K
def f(x):
    return x//1
if f(b)-f(a)>=1:
    print("OK")
elif A%K==0:
    print("OK")
else:
    print("NG")
Buggy code:
k = int(input())
a, b = map(int, input().split())
for i in range(a, b+1):
  if k % i == 0:
    print("OK")
  else:
    print("NG")

Fixed code:
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')
Buggy code:
K = int(input())
A, B = map(int,input().split())
C = A % K
if B - A >= K - 1:
  print('OK')
elif C == o:
  print('OK')
elif C + B - A >= K:
  print('OK')
else:
  print('NG')

Fixed code:
K = int(input())
A, B = map(int,input().split())
C = A % K
if B - A >= K - 1:
  print('OK')
elif C == 0:
  print('OK')
elif C + B - A >= K:
  print('OK')
else:
  print('NG')
Buggy code:
k=int(input())
a,b = map(int,input().split())

while b>=a:

    if b%k==0:
        print('OK')
        break

    b-=1

if b<a:
    print('NO')

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

while b>=a:

    if b%k==0:
        print('OK')
        break

    b-=1

if b<a:
    print('NG')
Buggy code:
# -*- coding: utf-8 -*-

k = int(input())


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

if k==1:
    print("OK")
elif abs(a-b) + a%k >= k-1:
    print("OK")
# elif a//k != b//k:
#     print("OK")
else:
    print("NG")


Fixed code:
# -*- coding: utf-8 -*-

k = int(input())


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

if k==1:
    print("OK")
elif a%k == 0:
    print("OK")
elif abs(a-b) + a%k >= k:
    print("OK")
# elif a//k != b//k:
#     print("OK")
else:
    print("NG")
Buggy code:
# coding: utf-8
# Your code here!

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('NO')

Fixed code:
# coding: utf-8
# Your code here!

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')
Buggy code:
k = input()
l = input().split()
A, B = l[0], l[1]

i = 0
while i * k <= B:
  if A <= i*k <= B:
    print('OK')
    break
  i += 1
else:
  print('NG')

Fixed code:
k = int(input())
l = input().split()
A, B = int(l[0]), int(l[1])

i = 0
while i * k <= B:
  if A <= i*k <= B:
    print('OK')
    break
  i += 1
else:
  print('NG')
Buggy code:

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("NO")

Fixed code:
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")
Buggy code:
K=int(input())
A,B=map(int,input().split())

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


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

for i in range(1000):
    if A<=i*K and i*K<=B:
        print('OK')
        exit()
print('NG')
exit()
Buggy code:
k = int(input())
a,b = map(int, input().split())
s = 0
z = b - a

for i in range(0, z):
  
  if (a + i) % k == 0:
    s = 1
    

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

Fixed code:
k = int(input())
a,b = map(int, input().split())
s = 0
z = b - a + 1



for i in range(0, z):
  
  if (a + i) % k == 0:
    s = 1
    

    
if s == 1:
  print("OK")
else:
  print("NG")
Buggy code:
k=int(input())
a=list(map(int,input().split()))
b=k*(a[0]//k)+k
if b<=a[1]:
    print('OK')
else:
    print('NG')

Fixed code:
k=int(input())
a=list(map(int,input().split()))
b=k*(a[0]//k)
if b==a[0]:
    print('OK')
elif b+k<=a[1]:
        print('OK')
else:
        print('NG')
Buggy code:
k=int(input())
a,b=map(int,input().split())
count=0
for i in range(a,b+1):
  if i%7==0:
    count+=1
if count>=1:
  print('OK')
else:
  print('NG')
  
  

Fixed code:
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>=1:
  print('OK')
else:
  print('NG')
Buggy code:
K = int(input())
A, B = [int(n) for n in input().split()]
ans = 'NO'
for i in range(A, B+1):
    if i%K == 0:
        ans = 'OK'
        break
print(ans)


Fixed code:
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)
Buggy code:
k = int(input())
a_b = input().split()[1].split(" ")
a = int(a_b.split(" ")[0])
b = int(a_b.split(" ")[1])

for i in range(1, 1000):
  if a<= (i* k) <= b:
    print("OK")
    break
  elif (i* k) > b:
    print("NG")
    break
else:
    print("NG")


Fixed code:
k = int(input())
a_b = input()
a = int(a_b.split(" ")[0])
b = int(a_b.split(" ")[1])

for i in range(1, 1000):
  if a<= (i* k) <= b:
    print("OK")
    break
  elif (i* k) > b:
    print("NG")
    break
else:
    print("NG")
Buggy code:
K = int(input())
A, B = map(int, input().split())
flag = 1
for i in range(A, B+1):
  if i % K == 0:
    flag = 1
print("OK" if flag else "NG")

Fixed code:
K = int(input())
A, B = map(int, input().split())
flag = 0
for i in range(A, B+1):
  if i % K == 0:
    flag = 1
print("OK" if flag else "NG")
Buggy code:
k=int(input())
a,b=map(int, input().split())

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

print('NG')

Fixed code:
k = int(input())
a, b = list(map(int, input().split()))
flag = 0
for i in range(a, b+1):
  if i % k == 0:
    print("OK")
    flag = 1
    break
if flag == 0:
  print("NG")
Buggy code:
n=int(input())
temp=list(map(int,input().rstrip().split()))
a=temp[0]
b=temp[1]
rem=(a%n)
left=n-rem
if b>=(left+a+1) :
    print("OK")
else :
    print("NG")



Fixed code:
n=int(input())
temp=list(map(int,input().rstrip().split()))
a=temp[0]
b=temp[1]
rem=(a%n)
left=n-rem
if b>=(left+a) :
    print("OK")
elif a%n ==0 or b%n==0:
    print("OK")
else :
    print("NG")
Buggy code:
N = int(input())
A, B = map(int, input().split())

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

print("NG")


Fixed code:
N = int(input())
A, B = map(int, input().split())

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

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

Fixed code:
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")
Buggy code:
k=int(input())
a,b=map(int, input().split())
ok=False
for i in range(a, b+1):
  ok = ok or i % k
print(['NG','OK'][ok])

Fixed code:
k=int(input())
a,b=map(int, input().split())
ok=False
for i in range(a, b+1):
  ok = ok or (i % k == 0)
print(['NG','OK'][ok])
Buggy code:
K = int(input())
A, B = map(int, input().split())

if (B // K) * B >= A:
    print('OK')
else:
    print('NG')


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

if (B // K) * K >= A:
    print('OK')
else:
    print('NG')
Buggy code:
K = int(input())
A, B = map(int, input().split())

if (B - A + 1) >= K:
    print("OK")
else:
    result = "NO"
    for i in range(A, B + 1):
        if i % K == 0:
            result = "OK"
            break
    print(result)


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

if (B - A + 1) >= K:
    print("OK")
else:
    result = "NG"
    for i in range(A, B + 1):
        if i % K == 0:
            result = "OK"
            break
    print(result)
Buggy code:
k = int(input())
a, b = map(int, input().split())
if (k <= (b-a)):
    print("OK")
else:
    for i in range(a, b+1):
        if i % k == 0:
            print("OK")
            break;
        print("NG")

Fixed code:
k = int(input())
a, b = map(int, input().split())
if (k <= (b-a)):
    print("OK")
else:
    count = 0
    for i in range(a, b+1):
        if i % k == 0:
            print("OK")
            count = 1
            break;
    if count == 0:
        print("NG")
Buggy code:
k = int(input())
a, b = map(int,input().split())

if b//k - a//k > 0:
    print("OK")
else:
    print("NG")

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

if b//k - a//k > 0:
    print("OK")
elif b%k == 0:
    print("OK")
elif a%k == 0:
    print("OK")
else:
    print("NG")
Buggy code:
n=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)

Fixed code:
n=int(input())
a,b=map(int,input().split())
ans='NG'
for i in range(a,b+1):
  if i%n==0:
    ans='OK'
print(ans)
Buggy code:
K = int(input())
A, B = map(int, input().split())

nK = K
n = 1
ans = "NG"
while(nK=<B):
  if nK >= A:
    ans = "OK"
    break
  n += 1
  nK = n * K
print(ans)

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

nK = K
n = 1
ans = "NG"
while(nK<=B):
  if nK >= A:
    ans = "OK"
    break
  n += 1
  nK = n * K
print(ans)
Buggy code:
k = int(input())
a,b = map(int,input().split())
if b%k==0:
  print("OK")
elif (b//k)*k >=a:
  print("OK")
else:
  print("NO")

Fixed code:
k = int(input())
a,b = map(int,input().split())
if b%k==0:
  print("OK")
elif (b//k)*k >=a:
  print("OK")
else:
  print("NG")
Buggy code:
k = int(input())
a, b = map(int,input().split())

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

Fixed code:
k = int(input())
a, b = map(int,input().split())
 
if a%k == 0:
  print("OK")
elif b%k == 0:
  print("OK")
elif b//k-a//k == 0:
  print("NG")
else:
  print("OK")
Buggy code:
k=int(input())
a,b=map(int,input().split())
for i in range(a,b+1):
  if i%k==0:
    print("OK")
    exit()
print("NO")

Fixed code:
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")
Buggy code:
n = int(input())
a,b = input().split()
a = int(a)
b = int(b)
for i in range(a, b+1):
  print(i)
  if i%n == 0:
    print("OK")
    exit()
print("NG")

Fixed code:
n = int(input())
a,b = input().split()
a = int(a)
b = int(b)
for i in range(a, b+1):
  if i%n == 0:
    print("OK")
    exit()
print("NG")
Buggy code:
K = int(input())
A,B = map(int,input().split())

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

Fixed code:
K=int(input())
A, B=map(int, input().split(" "))
a=0
for i in range(A, B+1):
    if i%K==0:
        a=1
        break
    else:
        a=0
if a==1:
    print("OK")
else:
    print("NG")
Buggy code:
k = int(input())
a, b = map(int, input().split())
for i in range(a, b):
    if i % k ==0:
        print('OK')
        break
else:
    print('NG')

Fixed code:
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")
Buggy code:
K = int(input())
A, B = map(int, input().split())

l = K
ans = 'NG'
for l in range(K, 1001, K):
    print(l)
    if l >= A and l <= B:
        ans = 'OK'
        break
    elif l > B:
        break

print(ans)

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

l = K
ans = 'NG'
for l in range(K, 1001, K):
#     print(l)
    if l >= A and l <= B:
        ans = 'OK'
        break
    elif l > B:
        break

print(ans)
Buggy code:
K = input()
A, B = [int(a) for a in input().split()]
p = A // K + K
if A < p and B < p:
    print("OK")
else:
    print("NG")

Fixed code:
K = int(input())
A, B = [int(a) for a in input().split()]
p = (A // K) * K
if (A <= p and p <= B) or (A <= p + K and p + K <= B):
    print("OK")
else:
    print("NG")
Buggy code:
k=int(input())
a,b=map(int,input().split())

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

Fixed code:
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")