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):
import sys
readline = sys.stdin.readline

K = int(readline())
A, B = map(int, readline().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())
t=0
while t<=B:
    if t>=A:
        print('OK')
        exit()
    t+=K
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):
a = int(input())
c,d = map(int, input().split())

for i in range(c,d+1):
  if i % a ==0:
    print('OK')
    exit()
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):
import math
k = int(input())
a,b = map(int,input().split())
if math.ceil(a/k)*k <=b:
  print("OK")
else:
  print("NG")

Solution (Python):
def main(sample_file = ''):

    """ convenient functions
    
    
    
    
    
    """

    """convenient decorator
    
    
        
        
        
        
        
        
        
        
        
        
    """
    
    
    import sys
    sys.setrecursionlimit(10**7)
    from itertools import accumulate, combinations, permutations, product 
    
    from math import factorial, ceil, floor, sqrt
    def factorize(n):
        """return the factors of the Arg and count of each factor
        
        Args:
            n (long): number to be resolved into factors
        
        Returns:
            list of tuples: factorize(220) returns [(2, 2), (5, 1), (11, 1)]
        """
        fct = []  
        b, e = 2, 0  
        while b * b <= n:
            while n % b == 0:
                n = n // b
                e = e + 1
            if e > 0:
                fct.append((b, e))
            b, e = b + 1, 0
        if n > 1:
            fct.append((n, 1))
        return fct
    def combinations_count(n, r):   
        """Return the number of selecting r pieces of items from n kinds of items.
        
        Args:
            n (long): number
            r (long): number
        
        Raises:
            Exception: not defined when n or r is negative
        
        Returns:
            long: number
        """
        
        if n < 0 or r < 0:
            raise Exception('combinations_count(n, r) not defined when n or r is negative')
        if n - r < r: r = n - r
        if r < 0: return 0
        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 combinations_with_replacement_count(n, r):
        """Return the number of selecting r pieces of items from n kinds of items allowing individual elements to be repeated more than once.
        
        Args:
            n (long): number
            r (long): number
        
        Raises:
            Exception: not defined when n or r is negative
        
        Returns:
            long: number
        """
        if n < 0 or r < 0:
            raise Exception('combinations_with_replacement_count(n, r) not defined when n or r is negative')
        elif n == 0:
            return 1
        else:
            return combinations_count(n + r - 1, r)
    from bisect import bisect_left, bisect_right
    from collections import deque, Counter, defaultdict 
    from heapq import heapify, heappop, heappush, heappushpop, heapreplace,nlargest,nsmallest 
    from copy import deepcopy, copy 
    import operator
    from operator import itemgetter 
    
    
    from functools import reduce, lru_cache
    def chmin(x, y):
        """change minimum
        if x > y, x = y and return (x, True).
        convenient when solving problems of dp[i]
        
        Args:
            x (long): current minimum value
            y (long): potential minimum value
        
        Returns:
            (x, bool): (x, True) when updated, else (x, False)
        """
        if x > y:
            x = y
            return (x, True)
        else:
            return (x, False)
    def chmax(x, y):
        """change maximum
        if x < y, x = y and return (x, True).
        convenient when solving problems of dp[i]
        
        Args:
            x (long): current maximum value
            y (long): potential maximum value
        
        Returns:
            (x, bool): (x, True) when updated, else (x, False)
        """
        if x < y:
            x = y
            return (x, True)
        else:
            return (x, False)

    from fractions import gcd 
    def gcds(numbers):
        return reduce(gcd, numbers)
    def lcm(x, y):
        return (x * y) // gcd(x, y)
    def lcms(numbers):
        return reduce(lcm, numbers, 1)
    def make_divisors(n, reversed=False):
        """create list of divisors
        
        Args:
            number (int): number from which list of divisors is created
            reversed (bool, optional): ascending order if False. Defaults to False.
        
        Returns:
            list: list of divisors
        """
        divisors = set()
        for i in range(1, int(n**0.5)+1):
            if n % i == 0:
                divisors.add(i)
                divisors.add(n//i)
        return sorted(list(divisors),reverse=reversed)
    
    
    
    INF = 10 ** 18
    MOD = 10 ** 9 + 7
    AtoZ = list('abcdefghijklmnopqrsruvwxyz')
    modpow = lambda a, n, p = MOD: pow(a, n, p) 
    def modinv(a, p = MOD):
        
        
        return modpow(a, p-2, p)
    def modinv_list(n, p = MOD):
        if n <= 1:
            return [0,1][:n+1]
        else:
            inv_t = [0,1]
            for i in range(2, n+1):
                inv_t += [inv_t[p % i] * (p - int(p / i)) % p]
            return inv_t
    def modfactorial_list(n, p = MOD):
        if n == 0:
            return [1]
        else:
            l = [0] * (n+1)
            tmp = 1
            for i in range(1, n+1):
                tmp = tmp * i % p
                l[i] = tmp
            return l
    def modcomb(n, k, fac_list = [], p = MOD):
        
        
        from math import factorial
        if n < 0 or k < 0 or n < k: return 0
        if n == 0 or k == 0: return 1
        if len(fac_list) <= n:
            a = factorial(n) % p
            b = factorial(k) % p
            c = factorial(n-k) % p
        else:
            a = fac_list[n]
            b = fac_list[k]
            c = fac_list[n-k]
        return (a * modpow(b, p-2, p) * modpow(c, p-2, p)) % p
    def modadd(a, b, p = MOD):
        return (a + b) % MOD
    def modsub(a, b, p = MOD):
        return (a - b) % p
    def modmul(a, b, p = MOD):
        return ((a % p) * (b % p)) % p
    def moddiv(a, b, p = MOD):
        return modmul(a, modpow(b, p-2, p))

    class UnionFindTree:
        """union find tree class
        TODO: fix this description...
        how to use (example):
        >>  uf = UnionFindTree(N) 
        >>  if uf.find_root(a) == uf.find_root(b):
        >>      do something
        >>  else:
        >>      do something
        >>      uf.unite(a, b)
        """
        def __init__(self, N):
            self.root = [-1] * (N+1)
            self.rank   = [0]  * (N+1)
            self.connected_num = [1] * (N+1)
    
        def find_root(self,x):
            root = self.root
            while root[x] != -1:
                x = root[x]
            return x
    
        def unite(self,x,y):
            root = self.root
            rank = self.rank
            connected_num = self.connected_num
            find_root = self.find_root
    
            rx = find_root(x)
            ry = find_root(y)
            if rx != ry:
                if rank[rx] < rank[ry]:
                    root[rx] = ry
                    rx,ry = ry,rx
                else:
                    if rank[rx] == rank[ry]:
                        rank[rx] += 1
                    root[ry] = rx       
                connected_num[rx] += connected_num[ry]

    
    
    
    
    

    def BellmanFord(N, M, ABC, vertex_start, vertex_end, value_if_inf = -1, find_shortest = False):
        """to calculate furthest or shortest length between vertex_start and vertex_end using BellmanFord algorithm
        
        Args:
            N (int): number of vertices
            M (int): number of edges
            ABC (list): [(ai, bi, ci) for _ in range(N)] where i-th edge is directed from vertex ai to vertex bi and the length is ci 
            vertex_start (int): start vertex. usually use 0.
            vertex_end (int): end vertex. usually use N-1.
            value_if_inf (int or string as you like, optional): value you want when the furthest (or shortest) distance is infinite (or -infinite). Defaults to -1.
            find_shortest (bool, optional): choose False to find furthest path. Defaults to False.
        
        Returns:
            int or string: normally int (but can be str if you set value_if_inf to str)
            
        Example:
                N, M, P = R()
                ABC = [R() for _ in range(M)]
                ABC = [(a-1, b-1, c-P) for a, b, c in ABC]
                print(BellmanFord(N, M, ABC, 0, N-1, value_if_inf = 'inf'))

        """

        def make_reachable_list(N, M, ABC, vertex_start, vertex_end):
            reachable_to_direct = defaultdict(list)
            reachable_from_direct = defaultdict(list)
            reachable_from_start = [False] * N
            reachable_to_end = [False] * N
            reachable_from_start[vertex_start] = True
            reachable_to_end[vertex_end] = True
            reachable_from_both_sides = [False] * N
            dfs_from_start = []
            dfs_to_end = []
            for a, b, c in ABC:
                reachable_to_direct[a].append(b)
                reachable_from_direct[b].append(a)
                if a == vertex_start:
                    dfs_from_start.append(b)
                    reachable_from_start[b] = True
                if b == vertex_end:
                    dfs_to_end.append(a)
                    reachable_to_end[a] = True
            while dfs_from_start:
                v = dfs_from_start.pop()
                for i in reachable_to_direct[v]:
                    if not reachable_from_start[i]:
                        reachable_from_start[i] = True
                        dfs_from_start.append(i)
            while dfs_to_end:
                v = dfs_to_end.pop()
                for i in reachable_from_direct[v]:
                    if not reachable_to_end[i]:
                        reachable_to_end[i] = True
                        dfs_to_end.append(i)
            for i in range(N):
                reachable_from_both_sides[i] = reachable_from_start[i] and reachable_to_end[i]
            return reachable_from_both_sides
        
        reachable_from_both_sides = make_reachable_list(N, M, ABC, vertex_start, vertex_end)
        
        if find_shortest:
            dist = [INF for i in range(N)]
        else:
            dist = [-INF for i in range(N)]
        
        dist[vertex_start] = 0
        for i in range(N):
            updated = False
            for a, b, c in ABC:
                if not reachable_from_both_sides[a]:
                    continue
                elif find_shortest:
                    update_condition = dist[a] + c < dist[b]
                else:
                    update_condition = dist[a] + c > dist[b]
                if dist[a] != INF and update_condition:
                    dist[b] = dist[a] + c
                    updated = True
                    if i == N-1:
                        return value_if_inf
            if not updated:
                break
        return dist[vertex_end]

    """ initialize variables and set inputs
    
        
        
            
            
    
        
        
        
        
        
        
        
    
        
        
        
        
    
        
        
    """

    
    r = lambda: sys.stdin.readline().strip()
    r_int = lambda: int(r())
    r_float = lambda: float(r())
    R = lambda: list(map(int, r().split()))
    R_str = lambda: r().split()
    R_map = lambda: map(int, r().split())
    R_float = lambda: list(map(float, r().split()))
    R_tuple = lambda: tuple(map(int, r().split()))

    """ how to treat input
    
    
    
    
    
    
    
    """

    
    if sample_file:
        sys.stdin = open(sample_file)
        
    
    
    
    K = r_int()
    A, B = R()
    for i in range(A, B+1):
        if i % K == 0:
            print('OK')
            return
    print('NG')
    
    
    
    
    

    """memo: how to use defaultdict of list
    
    Dic = defaultdict(list)
    
    Dic[x].append(y)
    
    for k, v in Dic.items():
    """
    
    """memo: how to solve binary problems
    
    >>> a = 5
    >>> bin_str_a = format(a, '
    >>> print(bin_str_a)
    0b0101 
    """
    
    """memo: how to solve the problem
    creating simple test/answer
    greed
    simple dp
    graph
    """

if __name__ == '__main__':
    main()

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

Solution (Python):

import numpy as np
from collections import deque
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):
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):


import sys

DEBUG = False

def read(t):
    return t(sys.stdin.readline().rstrip())


def read_list(t, sep = " "):
    return [t(s) for s in sys.stdin.readline().rstrip().split(sep)]


def dprint(*args, **kwargs):
    if DEBUG:
        print(*args, **kwargs)
    return


def main():
    k = read(int)
    a, b = read_list(int)
    for i in range(a, b + 1):
        if i % k == 0:
            print("OK")
            return
    print("NG")


if __name__ == "__main__":
    main()

Solution (Python):
K = int(input())
A,B = [int(i) for i in input().split(" ")]

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

Solution (Python):
import sys

sys.setrecursionlimit(10 ** 8)

input = sys.stdin.readline


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")
            return
    print("NG")

    

if __name__ == '__main__':
    main()

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

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

Solution (Python):
INT = lambda: int(input())
INTM = lambda: map(int,input().split())
STRM = lambda: map(str,input().split())
STR = lambda: str(input())
LIST = lambda: list(map(int,input().split()))
LISTS = lambda: list(map(str,input().split()))
def do(): 
    flg=0
    k=INT()
    a,b=INTM()
    for i in range(a,b+1):
        if i%k==0:
            flg=1
    if flg==0:
        print('NG')
    else:
        print('OK')
if __name__ == '__main__':
    do()

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

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





print('NG')

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(0)

print("NG")

Solution (Python):
import sys
sys.setrecursionlimit(10**9)
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())
import sys

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

Solution (Python):
import bisect
import collections
import sys

sys.setrecursionlimit(100000)
input = sys.stdin.readline
ACMOD = 1000000007
INF = 1 << 62


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


def llmi(n):
    return [lmi() for _ in range(n)]


K = int(input())
A, B = lmi()
for i in range(1001):
    if A <= K * i and K * i <= B:
        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):
import sys
input=sys.stdin.readline
sys.setrecursionlimit(10 ** 6)




















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 == 1:
    print("OK")
else:
    print("NG")

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):
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**7)
INF = 10**10
MOD = 10**9 + 7
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
int1 = lambda x: int(x) - 1
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
sys.setrecursionlimit(500000)

K = int(readline())
A, B = map(int, readline().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())

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

print('NG')

Solution (Python):


import sys
INT_MAX = sys.maxsize
INT_MIN = -(sys.maxsize)-1
sys.setrecursionlimit(10**7)
mod = 1000000007


def IOE():
    sys.stdin = open("input.txt", "r")
    sys.stdout = open("output.txt", "w")


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


if __name__ == "__main__":
    try:
        IOE()
    except:
        pass
    main()

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):
import numpy as np
import sys
import math
read = sys.stdin.readline

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

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

print("NG")

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

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

Solution (Python):
import sys
import math
from collections import deque
import heapq
MAX_INT = int(10e10)
MIN_INT = -MAX_INT
mod = 1000000007
sys.setrecursionlimit(1000000)
def IL(): return list(map(int,input().split()))
def SL(): return input().split()
def I(): return int(sys.stdin.readline())
def S(): return input()

K = I()
a,b = IL()

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")
        break
else:
    print("NG")

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

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

print('NG')

Solution (Python):

import sys
input = sys.stdin.readline

k = int(input())
a, b = map(int, input().split())
ok = False
for i in range(1, 1001):
    if a <= k * i <= b:
        ok = True
if ok:
    print("OK")
else:
    print("NG")

Solution (Python):











import sys
sys.setrecursionlimit(10**6)
input=sys.stdin.readline
from math import floor,sqrt,factorial,hypot,log 
from heapq import heappop, heappush, heappushpop
from collections import Counter,defaultdict,deque
from itertools import accumulate,permutations,combinations,product,combinations_with_replacement
from bisect import bisect_left,bisect_right
from copy import deepcopy
from fractions import gcd
from random import randint
def ceil(a,b): return (a+b-1)//b
inf=float('inf')
mod = 10**9+7
def pprint(*A): 
    for a in A:     print(*a,sep='\n')
def INT_(n): return int(n)-1
def MI(): return map(int,input().split())
def MF(): return map(float, input().split())
def MI_(): return map(INT_,input().split())
def LI(): return list(MI())
def LI_(): return [int(x) - 1 for x in input().split()]
def LF(): return list(MF())
def LIN(n:int): return [I() for _ in range(n)]
def LLIN(n: int): return [LI() for _ in range(n)]
def LLIN_(n: int): return [LI_() for _ in range(n)]
def LLI(): return [list(map(int, l.split() )) for l in input()]
def I(): return int(input())
def F(): return float(input())
def ST(): return input().replace('\n', '')
def main():
    K=I()
    A,B=MI()
    if(A%K==0 or A//K!=B//K or B%K==0):
        print("OK")
    else:
        print("NG")
if __name__ == '__main__':
    main()

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')
        break
else:
    print('NG')

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

num1 = (A-1)//K
num2 = B//K

if num1 != num2:
    print('OK')
else:
    print('NG')

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

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

Solution (Python):

import bisect
import heapq
import math
import random
import sys
from collections import Counter, defaultdict, deque
from decimal import ROUND_CEILING, ROUND_HALF_UP, Decimal
from functools import lru_cache, reduce
from itertools import combinations, combinations_with_replacement, product, permutations
from operator import add, mul, sub


input = sys.stdin.buffer.readline
INF = 2**62-1

def read_int():
    return int(input())


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


def read_float():
    return float(input())


def read_float_n():
    return list(map(float, input().split()))


def read_str():
    return input().strip()


def read_str_n():
    return list(map(str, input().split()))


def error_print(*args):
    print(*args, file=sys.stderr)


def mt(f):
    import time

    def wrap(*args, **kwargs):
        s = time.time()
        ret = f(*args, **kwargs)
        e = time.time()

        error_print(e - s, 'sec')
        return ret

    return wrap


@mt
def slv(K, A, B):
    ans = 0
    for i in range(100000):
        if A <= i*K <= B:
            return 'OK'
        if i * K > B:
            break
    return 'NG'


def main():
    K = read_int()
    A, B = read_int_n()
    print(slv(K, A, B))


if __name__ == '__main__':
    main()

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
input= lambda: sys.stdin.readline().rstrip()
def pin(type=int):return map(type,input().split())
def tupin(t=int):return tuple(pin(t))

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

resolve()

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):
import sys
from math import ceil, floor, sqrt, sin, cos, pi
from itertools import accumulate, permutations, combinations
from fractions import gcd 
from collections import deque, Counter
from operator import itemgetter
from heapq import heappop,heappush
sys.setrecursionlimit(10**7)
def lcm(x, y): return ((x * y) // gcd(x, y)) 

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):
def LI():return list(map(int,input().split()))




k=int(input())
a,b=LI()

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

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

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

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

Solution (Python):
k = int(input())
a, b = [int(i) for i in 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())
a=False
for i in range(A,B+1):
    if i%K==0:
        a=True
print("OK" if a 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"
print(ans)

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

Solution (Python):
ii = lambda : int(input())
mi = lambda : map(int,input().split())
li = lambda : list(map(int,input().split()))

k = ii()
a,b = mi()

flag = 0
for i in range(a,b+1):
    if i % k == 0:
        flag = 1
if flag:
    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,1):
    if i%K==0:
        print("OK")
        sys.exit()
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")
        quit()
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):
n=int(input())
a,b=map(int,input().split())
t=b//n
if t*n>=a:
    print('OK')
else:
    print('NG')

Solution (Python):
import sys

readline = sys.stdin.buffer.readline
sys.setrecursionlimit(10 ** 8)
INF = float('inf')
MOD = 10 ** 9 + 7


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'
    print(ans)
if __name__ == '__main__':
    main()

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):
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")
        break
    elif i == b:
        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')


if __name__ == "__main__":
    main()

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

ans = b//k - (a - 1)//k
print('OK' if ans > 0 else 'NG')

Solution (Python):

import sys


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



def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    K = int(next(tokens))  
    A = int(next(tokens))  
    B = int(next(tokens))  
    solve(K, A, B)


if __name__ == '__main__':
    main()

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


def main():
    K = int(input())
    A, B = map(int, input().split())
    for v in range(A, B + 1):
        if v % K == 0:
            print('OK')
            sys.exit()
    print('NG')


if __name__ == '__main__':
    main()

Solution (Python):
K=int(input())
A,B=[int(x) for x in input().rstrip().split()]



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