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



Sample input:
7
500 600


Sample output:
OK

Submission status: Wrong Answer

Solution code:
def solve(a, b, k):
    if a == b:
        return a % k == 0
    return a / k < b / k

assert solve(11, 11, 1)
assert solve(3, 3, 3)
assert solve(1, 2, 3) == False
assert solve(5, 7, 4) == False
assert solve(7, 7, 7)
assert solve(3, 7, 4)
assert solve(5, 8, 4)
assert solve(5, 9, 4)
assert solve(500, 600, 7)

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

print 'OK' if solve(a, b, k) else 'NG'

Submission status: Wrong Answer

Solution code:
i=int(input())
n,m=map(int,input().split())
if n%i==0:
  print('OK')
elif m%i==0:
  print('OK')
else:
  if i<=m-n:
    print('OK')
  else:
    print('NG')

Submission status: Wrong Answer

Solution code:
I = [input() for i in range(2)]
K = int(I[0])
S = I[1].split()
A = int(S[0])
B = int(S[1])

na = A//K
nb = B//K

#print(na)
#print(nb)

if na < nb :
    ans = 'OK'
else:
    ans = 'NG'

print(ans)

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

Solution code:
k = int(input())
a,b=(int(x) for x in input().split())
x = a / k
y = b / k
z = int(y) - int(x)
sum = 0
for i in range(z):
    sum = sum + 1
if k == 1:
    print("OK")
elif sum == 0:
    print("NG")
else:
    print("OK")

Submission status: Wrong Answer

Solution code:
K=int(input())

A,B=list(map(int, input().split()))
i=0
for i in range(A,B+1):
    if i%K==0:
        print("Yes")
        i=1
if i==0:
    
    print("No")

Submission status: Wrong Answer

Solution code:
k=int(input())
a,b=map(int,input().split())
if (b-a+1)>=k:
    print('OK')
else:
    print('NG')

Submission status: Wrong Answer

Solution code:
K = int(input())
A,B = map(int,input().split())
x = A % K
if K % A == 0 or K % B == 0:
    print("OK")
elif K - x <= B-A:
    print("OK")
else:
    print("NG")

Submission status: Wrong Answer

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

print("OK" if abs((B // K) - (A // K)) > 0 or abs(B - A) == 0 or B // K > 0 else "NG")

Submission status: Wrong Answer

Solution code:
#入力
K=int(input())
A,B=map(lambda x:int(x),input().split())

flag=False
i=0
num=0
while num<=B and num>=A:
	num=K*i
	if num>=A and num<=B:
		flag=True
		break
	else:
		i=i+1
      
if flag:
	print("OK")
else:
	print("NG")

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
K = int(input())
A,B = map(int, input().split())
C = K
count = 1
ans = "NG"

while (C<B):
    #print("test")
    if(A<=C and C<=B):
        ans ="OK"
    C = K*count
    count += 1
    #print(C)


print(ans)

Submission status: Wrong Answer

Solution code:
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)==A[1]%int(N) :
        print("OK")
     elif A[0]//int(N) != A[1]//int(N):
        print("OK")
     else:
         print("NG")

Submission status: Wrong Answer

Solution code:
k=input()
i=int(k)
k=int(k)
a,b=map(int,input().split())
result=0
while k<=b:
    if a<=k and k<=b:
        result=result+1
        k=k+k
    else:
        k=i+k
    print(k)
if result>0:
    print('OK')
else :
    print('NG')

Submission status: Wrong Answer

Solution code:
# coding: utf-8
# Your code here!
K = int (input())
line= list(map(int,input().split()))
a,b = line[0],line[1]
if b>K:
    print("NG")
elif (b-a+1)>=K:
    print("OK")

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

Submission status: Wrong Answer

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

p = A % K
q = B % K

if A==B:
	if p==0:
		print("OK")
	else:
		print("NG")
  
else:
	if B-A>K:
		print("OK")
	else:
		if p+q >K:
			print("OK")
		else:
			print("NG")

Submission status: Wrong Answer

Solution code:
K = int(input("multiple of: "))
A, B = map(int, input().split())
for i in range(1, 1000):
    M = K * i
    if M in range(A, B):
        print("OK")
        break
    elif i == 100 and M not in range(A, B):
        print("NG")
    else: 
        continue

Submission status: Wrong Answer

Solution code:
def main():
    K = int(input())
    A, B = map(int, input().split())
    hiku = (B/K) - (A/K)
    waru = B % K
    if hiku >= 1:
        print("OK")
    elif hiku == 0 and waru == 0:
        print("OK")
    else:
        print("NG")

main()

Submission status: Wrong Answer

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

if b / k - a / k > 1:
    print('OK')
elif a == b and a == k:
    print('OK')
else:
    print('NG')

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
K = input()
A,B = input().split(" ")
if int(B)-int(A) > int(K):
  print("'ok'")
else:
  print("'NG'")

Submission status: Wrong Answer

Solution code:
k = int(input())

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

if (b-a) / k >= 1:
    print('OK')
elif b % k == 0 or a % k == 0 :
    print('OK')
else:
    print('NG')

Submission status: Wrong Answer

Solution code:
k=int(input())
flag=0
ab=list(map(int, input().split()))
i=0
while ab[1]-ab[0]+1-i>0:
  if (ab[0]+i)%k==0:
    flag=1
    print("OK")
  i=i+1
if flag==0:
  print("NG")

Submission status: Wrong Answer

Solution code:
k=int(input())
a,b=map(int,input().split())
if b-a+1>=k:
    print('OK')
else:
    print('NG')

Submission status: Wrong Answer

Solution code:
K=int(input())
A,B = map(int, input("").split())
if (B-A)>=K:
    print("OK")
else:
    print("NG")

Submission status: Wrong Answer

Solution code:
k = int(input())
num = list(map(int, input().split()))
check = False
for i in num:
  if (i % k == 0):
    check = True
    break
print("OK" if check else "NG")

Submission status: Wrong Answer

Solution code:
k = int(input())
a,b = map(int,input().split())
if a%k == 0 or b%k ==0:
    print("OK")
elif a//k == b//k and a%k != b%k:
    print("NG")
else:
    print("OK")

Submission status: Wrong Answer

Solution code:
k=int(input())
a,b = map(int,input().split())
for i in range(1,b+1):
    if (k*i)<=b and (k*i)>=a:
        print("OK")
        break
    if i==b+1:
        print("NG")
        break

Submission status: Wrong Answer

Solution code:
num = int(input())
a,b = map(int, input().split())
if (a//num+1)*num <= b:
  print('OK')
elif num==1:
  if a==b:
    print('OK')
else:
  print('NG')

Submission status: Wrong Answer

Solution 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-1:
    print("OK")
# elif a//k != b//k:
#     print("OK")
else:
    print("NG")

Submission status: Wrong Answer

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

if (A-B) >= K:
    print("OK")
else:
    for a in range(1000):
        if a * K >= A:
            if a * K <= B:
                print("OK")
            break
    else:
        print("NG")

Submission status: Wrong Answer

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

C=A/K
D=B/K
if D-C<1 and D-C>0:
    print('NG')
else:
    print('OK')

Submission status: Wrong Answer

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

N = A // K

if K*(N+1) <= B:
  print("OK")
else:
  print("NG")

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

if K == 1:
  print("OK")
elif B % A >= K:
  print("OK")
else:
  print("NG")

Submission status: Wrong Answer

Solution code:
K = input()
K = int(K)
A,B = map(int,input().split())
if (B-A) >= K:
	print("OK")
elif K == 1:
	print("OK")
else:
	print("NG")

Submission status: Wrong Answer

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

c = int(B/K)

if B%K != 0:
    d = int(B/K - 1)
else:
    d = int(B/K)
 
if c <= d:
    print("OK")
else:
    print("NG")

Submission status: Wrong Answer

Solution code:
k=int(input())
a,b=map(int,input().split())
x=a//k
if a%k==0 or b%k==0:
	print("OK")
elif a<=x*(k+1)<=b:
	print("OK")
else:
	print("NG")

Submission status: Wrong Answer

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

if a-k>=k  and b-k>=a-k:
    print("OK")
else:
    print("NG")

Submission status: Wrong Answer

Solution code:
k = int(input())
[a, b] = [int(i) for i in input().split()]
sum = k
while sum <= 1000:
    sum += k
    if sum >= a and sum <= b:
        print("OK")
        break
else:
    print("NG")

Submission status: Wrong Answer

Solution code:
N = int(input())
A=input().split()

s=int(A[0])//N
if int(A[0])%N==0:
    print('OK')
else:
    if (s+1)*N>=int(A[1]):
        print('NG')
    else:
        print('OK')

Submission status: Wrong Answer

Solution code:
k = int(input())
a, b = map(int, input().split())
if a == b and a % k == 0:
  print('OK')
elif b // k - a // k >= 1:
  print('OK')
else:
  print('NG')

Submission status: Wrong Answer

Solution code:
K=int(input())
A,B=map(int,input().split())
C=B-A+1
if A<=K and K<=B:
    print("OK")

else:
    if C<K:
        print("NG")
    else:
        print("OK")

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

Solution code:
from sys import stdin

K = int(stdin.readline().rstrip())
A, B = [int(x) for x in stdin.readline().rstrip().split()]

if (K>B):
    print("NG")
if (A%K==0 or B%K==0):
    print("OK")
elif(B-(B%K)>=A) :
    print("OK")
else:
    print("NG")

Submission status: Wrong Answer

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

print("OK" if (B - A) // K > 0 or B // K > 0 else "NG")

Submission status: Wrong Answer

Solution code:
K = int(input())
A,B = map(int,input().split())
c = 0
if A == B:
  if B % K == 0:
    c += 1
else:
  for x in range(A,B):
    if (x+1) % K == 0:
      c += 1
      break

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

Submission status: Wrong Answer

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

res_A = A // K
res_B = B // K

if (1 < abs(res_A - res_B) ):
    print("OK")
elif(A % K ==0 or B % K ==0 ):
    print("OK")
else:
    print("NG")

Submission status: Wrong Answer

Solution code:
K = int(input())
a,b = map(int,input().split())

ka = a/K
kb = b/K
kaama = a%K
kbama = b%K



if kaama == 0 or kbama == 0:
  print("OK")
  
elif (kb-ka)>1:
  print("OK")
  
elif (kb-ka)==0:
  print("NG")

Submission status: Wrong Answer

Solution code:
def countDivisibles(A, B, M): 
      
    # Variable to store the counter 
    counter = 0; 
  
    # Running a loop from A to B 
    # and check if a number is  
    # divisible by M. 
    for i in range(A, B): 
        if (i % M == 0): 
            counter = counter + 1
  
    return counter 

k=int(input())
a,b=map(int,input().split())
t=countDivisibles(a,b,k)
if t>0:
    print("OK")
else:
    print("NG")

Submission status: Wrong Answer

Solution code:
k = int(input())
a, b = map(int,input().split())
ka = []
jl = []


for j in range(b):
  j+=1
  jl.append(j)
  

for i in range(b):
  i+=1
  ks = k * i 
  ka.append(ks)

  
if jl in ka:
  print("OK")
else:
  print("NG")

Submission status: Wrong Answer

Solution code:
import math

x = int(input())

print(math.ceil(math.log(x / 100, 1.01)))

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

Solution code:
K = int(input())
A,B = map(int,input().split())
a=0

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

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

Submission status: Wrong Answer

Solution code:
k = int(input())
l, u = map(int, input().split())

if k==1:
  print('OK')
  
else:
  tmp1 = (l-1)/k
  tmp2 = (u+1)/k
  print('OK' if tmp2-tmp1>=1 else 'NG')

Submission status: Wrong Answer

Solution 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")

Submission status: Wrong Answer

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

if floor(b / k) - floor(a / k) > 1:
    print('OK')
elif a == b and  a == k:
    print('NG')
else:
    print('NG')

Submission status: Wrong Answer

Solution code:
n = int(input())
m = list(map(int,input().split()))

sa = m[1] - m[0]
flag = 0
hantei = m[0]

if sa == 0:
    if sa % n == 0:
        print("OK")
        exit()
    else:
        print("NG")
        exit()

for x in range(sa):
    if hantei % n == 0:
        flag += 1
    hantei = (x+1) + m[0]

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

Submission status: Wrong Answer

Solution code:
import os
import sys

def main():
	k = int(input())
	a,b = map(int, input().split())
	list_a = []
	if b == a:
		print("OK")
		sys.exit()

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

if __name__ == "__main__":
	main()

Submission status: Wrong Answer

Solution code:
n=int(input())
temp=list(map(int,input().rstrip().split()))
a=temp[0]
b=temp[1]
result="OK"
i=1
while a<b :

    a+=i
    i+=1
    if a%n == 0 :
        result="NG"
        break
print(result)

Submission status: Wrong Answer

Solution code:
K=int(input())
A,B=map(int,input().split())
x=A
while x<=B:
  if x%K==0:
    print('OK')
    break
  else:
    x+=1
if x==B+1:
  print('No')

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

Solution code:
K=int(input())
A,B=map(int,input().split())
C=B-A+1
if A<=K<=B:
    print("OK")

else:
    if C<K:
        print("NG")
    else:
        print("OK")

Submission status: Wrong Answer

Solution code:
import sys

K = int(sys.stdin.readline().strip())
A, B = map(int, sys.stdin.readline().strip().split())
for i in range(1, 1001):
    if A <= K*i <= B:
        print("OK")
        sys.exit()
print("NO")

Submission status: Wrong Answer

Solution code:
K = int(input())
A,B = map(int, input().split())
N = int(1000 / K) + 1

OK = False

a = int(A/K)
b = int(B/K)

if a < b or K == 1:
    print('OK')
else:
    print('NG')

Submission status: Wrong Answer

Solution code:
K=int(input())
A,B = map(int, input("").split())
if ((B-A)>=K):
    print("OK")
else:
    print("NG")

Submission status: Wrong Answer

Solution code:
K = int(input())
a, b = map(int, input().split())
c = b-a
if c+1>=K or (K>=a and K<=b):
    print("OK")
else:
    print("NG")

Submission status: Wrong Answer

Solution 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")

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

Solution code:
def solve(n, x, y):
  for i in range(x, y+1):
    if i % n == 0:
      return "OK"
    
  return "NG"


n = int(input())
a, b = list(map(int, input().split()))
solve(n, a, b)

Submission status: Wrong Answer

Solution code:
check = False
n = int(input())
num = list(map(int, input().split()))
while num[0] < num[1] and check != True :
    if(num[0]%n==0):
        check=True;
    num[0] += 1
if(check):
    print("OK")
else:
    print("NG")

Submission status: Wrong Answer

Solution code:
k = int(input())
a, b = map(int,input().split())
c = a / k
d = b / k
intt = int(c) + 1
if c <= int(a) and int(a) <= d:
    print("OK")
elif c <= intt and intt <= d:
    print("OK")
else:
    print("NG")

Submission status: Wrong Answer

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

res_A = A // K
res_B = B // K

if (2 <= abs(res_A - res_B) ):
    print("OK")
elif(A % K ==0 or B % K ==0 ):
    print("OK")
else:
    print("NG")

Submission status: Wrong Answer

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

    a = A // K

    if A == B and A % K == 0:
        print("OK")
        return

    if (a + 1) * K <= B:
        print("OK")
    else:
        print("NG")


if __name__ == "__main__":
    main()

Submission status: Wrong Answer

Solution code:
K=int(input())
A_B=list(map(int,input().split()))
A=A_B[0]
B=A_B[1]
m=1
c=0
for i in range(B):
  m=i*K
  if(m>A and m<B):
    c=1
  else:
    c=0
if(c==1):
  print("OK")
else:
  print("NG")

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
k = int(input())
a, b = map(int, input().split())
count = 1
m = 0
while a >= m:
    m = k * count
    count += 1
if a <= m <= b:
    print("OK")
else:
    print("NG")

Submission status: Wrong Answer

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

if A%K !=0:
    c = int(B/K + 1)
else:
    c = int(B/K)

if B%K != 0:
    d = int(B/K - 1)
else:
    d = int(B/K)
 
if c <= d:
    print("OK")
else:
    print("NG")

Submission status: Wrong Answer

Solution code:
k=int(input())
a,b=map(int,input().split())
if b-a>=k-1:
    print('OK')
else:
    print('NG')

Submission status: Wrong Answer

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

if (((int(A)/K)+1) <= (int(B)/K)):
    print("OK")
elif(K==1):
    print("OK")
else:
    print("NG")

Submission status: Wrong Answer

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

print(
    "OK" 
    if K in (A, B) 
        or B - A >= K 
        or (A == B and A % K == 0)
    else "NG"
)

Submission status: Wrong Answer

Solution 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')

Submission status: Wrong Answer

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

aa=a/n
bb=b/n
nn=bb-aa

if nn >= 1:
    print('OK')
elif aa.is_integer():
    print('OK')
elif bb.is_integer():
    print('OK')
elif n == 1:
    print('OK')
else:
    print('NG')

Submission status: Wrong Answer

Solution code:
#---We Love Golf

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

#judge = b - a

q_1, mod_1 = divmod(a,K)
q_2, mod_2 = divmod(b,K)

if(K == 1):
  print("OK")
  exit()

if(q_1 == q_2 or b == K):
  print("NG")
else:
  print("OK")

Submission status: Wrong Answer

Solution code:
import sys
K = int(input())
if K == 1:
  print("OK")
  sys.exit()
A, B = map(int, input().split(" "))
ret = int(B / K - A / K)
if ret > 0:
  print("OK")
else:
  print("NG")

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

Solution 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
    else:
        continue
if count != 0:
    print("OK")
else:
    print("NG")

Submission status: Wrong Answer

Solution code:
K=int(input())
A,B=map(int,input().split())
x=A
while x<=B:
  if x%K==0:
    print('OK')
    break
  else:
    x+=1
if x==B:
  print('No')

Submission status: Wrong Answer

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

ans = "NG"
for i in range(B):
    if A <= K * i and K * i <= B:
        ans = "OK"
        break

print(ans)

Submission status: Wrong Answer

Solution code:
N = input()
A=input().split()

s=int(A[0])//int(N)
if int(A[0])%int(N)==0:
    print('OK')
else:
    if (s+1)*N>=A[1]:
        print('NG')
    else:
        print('OK')

Submission status: Wrong Answer

Solution code:
K = int(input())

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

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

Submission status: Wrong Answer

Solution code:
K = input()
A,B = input().split(" ")
if int(A) - int(B) > int(K):
  print("ok")
else:
  print("NG")

Submission status: Wrong Answer

Solution code:
num = int(input())
s, t = map(int, input().split())

flag = 0

for n in range(s, t):
  if n%num == 0:
    flag = 1

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

Submission status: Wrong Answer

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

vala = A//N
valb = B//N
if vala != valb:
    print('OK')
elif A == B and N == 1:
    print('OK')
else:
    print('NG')

Submission status: Wrong Answer

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

C=A/K
D=B/K
if D-C>=1:
    print('OK')
elif D-C==0:
    print('OK')
else:
    print('NG')

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

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

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

Submission status: Wrong Answer

Solution code:
k = int(input())
a, b = map(int, input().split())
i = 0
while i*k <= b:
    print(i*k)
    if a <= i*k <= b:
        print("OK")
        break
    i += 1
else:
    print("NG")

Submission status: Wrong Answer

Solution code:
K = int(input())
A, B = map(int, input().split())
if 1 <= K <= 1000 and 1 <= A <= B <= 1000:
  if K in range(A, B):
    print("OK")
  else:
    print("NG")

Submission status: Wrong Answer

Solution code:
I = [input() for i in range(2)]
K = int(I[0])
S = I[1].split()
A = int(S[0])
B = int(S[1])

na = K/A 
nb = K/B

if na < nb :
    ans = 'OK'
else:
    ans = 'NG'

print(ans)

Submission status: Wrong Answer

Solution code:
K = input()
A,B = input().split()
if A == B:
    ans = int(A)
    if ans % int(K) == 0:
        print('OK')
        exit()
    print('NG')
    exit()
for i in range(int(A), int(B)):
    if i % int(K) == 0:
        print('OK')
        exit()
    
print('NG')

Submission status: Wrong Answer

Solution 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")

Submission status: Wrong Answer

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

# if k == 1:
#     print('OK')
# if k > b:
#     print('NG')

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

print('NG')

Submission status: Wrong Answer

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

res_A = A // K
res_B = B // K

if (K <= abs(res_A - res_B) ):
    print("OK")
elif(A % K ==0 or B % K ==0 ):
    print("OK")
else:
    print("NG")

Submission status: Wrong Answer

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

a = int(A) // K
b = int(B) // K
if a == b and A !=B:
    print("NG")
else:
    print("OK")

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

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

num = a//k + 1

if a%k == 0 or b%k ==0:
    print('OK')
elif b/k - a/k >= 1:
    print('OK')
else:
    print('NG')

Submission status: Wrong Answer

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

if a<= int(a/k) * k <= b:
    print('OK')
else:
    print('NG')

Submission status: Wrong Answer

Solution 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")

Submission status: Wrong Answer

Solution code:
K = int(input())
A , B = (int(x) for x in input().split())


for i in range(1000):
    if A >= i*K >= B:
        print("OK")
        break
    elif i*K > B:
        print("NG")
        break

Submission status: Wrong Answer

Solution code:
k=int(input())
a,b = map(int,input().split())
for i in range(1,b):
    if (k*i)<=b and (k*i)>=a:
        print("OK")
        break
    if i==b:
        print("NG")
        break

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
k = int(input())
a, b = map(int, input().split())
if a == b and a % k == 0:
    print("OK")
    exit()
a = set([i for i in range(1,a+1) if not i%k])
b = set([i for i in range(1,b+1) if not i%k])
if len(b-a) == 0:
    print("NG")
else:
    print("OK")

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
x = int(input())
for i in range(10000):
  if (1.01)**i==0.01*x:
    print(i)

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

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

flg = False
for i in range(A, B):
	print(i)
	if i % K == 0:
		flg = True
		break

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

Submission status: Wrong Answer

Solution code:
K = int(input())
A, B = map(int,input().split())
n = 1
m = 1
for i in range(1100):
  if A <= K * i:
    n = i
for i in range(n, 1100):
  if B >= K * i:
    m = i - 1
if m - n >= 0:
  print("OK")
else:
  print("NG")

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
K = int(input())
A, B = (int(x) for x in input().split())
if A == B:
  if A%K == 0:
    print("OK")
  else:
    print("NG")
else:
  for i in range(A, B):
    if i%K == 0:
      print("OK")
      quit()
  print("NG")

Submission status: Wrong Answer

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

if k <= b-a+1 or (a<=k and k<=b) or (b % k >= b-a+1):
    print('OK')
else:
    print('NG')

Submission status: Wrong Answer

Solution code:
X = int(input())
S = 100
for i in range(1000000000000000):
    S += int((0.01) * S)
    if S >= X:
        print(i+1)
        break

Submission status: Wrong Answer

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

    print(ans)

if __name__ == '__main__':
    main()

Submission status: Wrong Answer

Solution code:
X = int(input())
A,B = map(int, input().split())
F = 0

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

Submission status: Wrong Answer

Solution code:
A = int(input())
X,Y = map(int,input().split())

if Y-X >= A:
  print("OK")
elif Y%A == 0 or X%A == 0:
  print("OK")
elif X <= A and A <= Y:
  print("OK")
else:
  print("NG")

Submission status: Wrong Answer

Solution code:
k = int(input())
l, u = map(int, input().split())

if k==1:
  print('OK')
  
else:
  tmp1 = l/k
  tmp2 = u/k
  print('OK' if tmp2-tmp1>=1 else 'NG')

Submission status: Wrong Answer

Solution code:
K = int(input())
A,B = map(int,input().split())
A_amari = A % K
B_amari = B % K
Saitannkyori = min(A_amari,B_amari)
if B-A >= Saitannkyori:
	print("OK")
else:
	print("NG")

Submission status: Wrong Answer

Solution code:
import sys
K = int(input())
if K == 1:
  print("OK")
  sys.exit()
A, B = map(int, input().split(" "))

ret = int(B / K) - int(A / K)
if ret > 0:
  print("OK")
else:
  print("NG")

Submission status: Wrong Answer

Solution code:
K=int(input())
A,B= list(map(int, input().split(' ')))
if B-A>K-1:
    print('OK')
else:
    l=0
    for i in range(0,B-A+2):
        if (A+i)%K==0:
            l=1
    if l==1:
        print('OK')
    else:
        print('NG')

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
K = input()
A,B=input().split()

k = int(K)
a = int(A)
b = int(B)
while True:

    for i in range(1000):
        kk = k * i
        if kk >= a and kk <= b:
            p = "OK"
    break
p = "NG"


print(p)

Submission status: Wrong Answer

Solution code:
n = int(input())

(a, b) = [int(s) for s in input().split()]

v = range(n, 1000, n)

v = [i for i in v if i >= a and i <= b]

ans = 'OK'

if len(v) == 0:
    ans = 'NG'

print(ans)

Submission status: Wrong Answer

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

p = A % K
q = B % K

if A==B:
	if p==0:
		print("OK")
	else:
		print("NG")
  
else:
	if p+q >K:
		print("OK")
	else:
		print("NG")