TnT/Multi_CodeNet4Repair huggingface dataset:
Problem: 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`.

Submission attempts (in order):
k = int(input)
a,b = map(int, input().sprit())
ans = False
for i in range(a,b+1) :
  if i%k == 0 : 
    ans = True

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


k = int(input)
a,b = map(int, input().sprit())
ans = False
for i in range(a,b+1) :
  if i%k == 0 : 
    ans = True

if ans==True : print('OK')
else : print('NG')
    


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

k = int(input())
a,b = map(int, input().sprit())
ans = False
for i in range(a,b+1) :
  if i%k == 0 : 
    ans = True

if ans==True : print('OK')
else : print('NG')
    


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

print(ans)

    


k = int(input)
a,b = map(int, input().sprit())
ans = False
for i in range(a,b+1) :
  if i%k == 0 : 
    ans = True

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


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)

    


Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
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")

a = int(input())

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

start = a * int(low//a)

boolean = False

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

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


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


Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
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')

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

Verdicts: Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
k = input()
a, b = input().split()

for cnt in range(int(b)):

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


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

for cnt in range(int(b)):
    if cnt+1 >= int(a):
       # print(cnt+1,int(k),int(cnt+1) % int(k))

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

Verdicts: Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
k=int(input())
a,b=map(int,input().split())
if(a%k==0|b%k==0|a//k-b//k!=0):
  print("OK")
else:
  print("NG")

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

Verdicts: Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
K = int(input())
A, B = map(int, input().split())
print(int(A / K))
print(int(B / K))

K = int(input())
A, B = map(int, input().split())
A1 = int(A / K)
A2 = int(A % K)
B1 = int(B / K)
# B2 = B % K
if (B1 - A1) >= 1 or A2 == 0:
  print('OK')
else:
  print('NG')


Verdicts: Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
def main():
  k=int(input())
  a,b = map(int,input().split())
  for i in range(1000):
    if(a<=i*k and i*k <= b):
      print("Yes")
      return 0
  print("No") 
  return 0

main()

def main():
  k=int(input())
  a,b = map(int,input().split())
  for i in range(1000):
    if(a<=i*k and i*k <= b):
      print("OK")
      return 0
  print("NG") 
  return 0

main()

Verdicts: Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
k = int(input())
a,b = map(int,input().split())
c = k
while(c <= b):
	if a <= k <= b:
		print("OK")
		quit()
    c += k
print("NG")

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

Verdicts: Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
import math
A, B, N = map(int,input().split())
ans = 0
for i in range(1,min(N,B)):
  X = math.floor(A*i//B)-A*math.floor(i//B)
  if(X>=ans):
    ans = X
print(ans)


K = int(input())
A, B = map(int,input().spilt())
if(A<=(B//K)*K){
  print("OK")
}
else{
  print("NG")
}


N = int(input())
A, B = map(int,input.split())
if(A<=B/K*K){
  print("OK")
}
else{
  print("NG")
}

K = int(input())
A, B = map(int,input.spilt())
if(A<=B/K*K){
  print("OK")
}
else{
  print("NG")
}

K = int(input())
A, B = map(int,input().spilt())
if(A<=B/K*K){
  print("OK")
}
else{
  print("NG")
}


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

Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
x = input()
x = x.split()
k = int(x[0])
a = int(x[1])
b = int(x[2])
if k <= b - a:
  print('OK')
else:
  if b % k <= a % k:
    print('OK')
  else:
    print('NG')

x = input()
k = int(x[0,0])
a = int(x[1, 0])
b = int(x[1, 1])
if k <= b - a:
  print('OK')
else:
  if b % k <= a % k:
    print('OK')
  else:
    print('NG')

x = input()
x = x.split()
x = x.split('/')
k = int(x[0])
a = int(x[1])
b = int(x[2])
if k <= b - a:
  print('OK')
else:
  if b % k <= a % k:
    print('OK')
  else:
    print('NG')


x = input()
x = x.split()
x = x.split(\n)
k = int(x[0])
a = int(x[1])
b = int(x[2])
if k <= b - a:
  print('OK')
else:
  if b % k <= a % k:
    print('OK')
  else:
    print('NG')


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

x = input()
x = x.split()
k = int(x[0])
a = int(x[1])
b = int(x[2])
if k <= b - a:
  print('OK')
else:
  if b % k <= a % k:
    print('OK')
  else:
    print('NG')
   

x = input()
x = x.split()
x = x.split('\n')
k = int(x[0])
a = int(x[1])
b = int(x[2])
if k <= b - a:
  print('OK')
else:
  if b % k <= a % k:
    print('OK')
  else:
    print('NG')


k = int(input())
a,b = int(input().split())
if k <= b - a:
  print('OK')
else:
  if b % k <= a % k:
    print('OK')
  else:
    print('NG')
   

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

Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Wrong Answer

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
K = int(input())
A, B = map(int, input().split())

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

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

Verdicts: Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
K = int(input())
A, B = map(int, input().split())

l = 0
ret = 'NG"
while l <= B:
  if l >= A:
    ret = 'OK'
  l += K
  
print(ret)

K = int(input())
A, B = map(int, input().split())
 
l = 0
ret = 'NG'
while l <= B:
  if l >= A:
    ret = 'OK'
  l += K
  
print(ret)

Verdicts: Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
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")


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

Verdicts: Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
K = input()
A = input()
B = input()

list=[]
up = int(A)

for i  in  range(int(B)-int(A)):
	list = list + [up]
	up += 1
list = list + [up]

count = 0

for t in list:
	if int(t) % int(K) ==0:
  		count+=1

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


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

list=[]
up = int(A)

for i  in  range(int(B)-int(A)):
	list = list + [up]
	up += 1
list = list + [up]

count = 0

for t in list:
	if int(t) % int(K) ==0:
  		count+=1

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


Verdicts: Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
K=int(input())
A,B=map(int,input().split())
a='NG'
for i in range(A,B+1):
  if i%K==0:
    a=='OK'
  break
print(a)
  

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

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


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

Verdicts: Wrong Answer

Wrong Answer

Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
N=int(input())
a, b = map(int, input().split())
def golf(N,a,b):
  for i in range(a,b+1):
    if i%N==0:
      return "OK"
    else:
      return "NG"
print(golf(N,a,b))

N=int(input())
a, b = map(int, input().split())
def golf(N,a,b):
  for i in range(a,b+1):
    if i%N==0:
      return "OK"
  return "NG"
print(golf(N,a,b))

Verdicts: Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
import math

A, B, N= (int(x) for x in input().split())
max = 0
x = B * math.floor(N/B) - 1
if x == -1:
    x = N
a = math.floor(A * x / B) - A * math.floor(x / B)
b = math.floor(A * N / B) - A * math.floor(N / B)
if a > b:
    print(a)
else:
    print(b)

import math

k = int(input())
a, b = (int(x) for x in input().split())
outa = math.floor(a / k)
outb = math.floor(b / k)
if outb == 0:
    print("NG")
elif outa == outb and a != b and outa != a / k:
    print("NG") 
else:
    print("OK")

Verdicts: Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):

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



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

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


Verdicts: Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
K = int(input())
A, B = map(int, input().split())

c = A / K
b = c * K
flag = False

if b == B:
  flag = True
while b <= B:
  b += K
  elif b <= B:
    flag = True

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


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

c = A / K
b = c * K
flag = False

if b == B:
  flag = True
b += K
  if b <= B:
    flag = True

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


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

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


Verdicts: Runtime Error

Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
K=int(input())
A,B=map(int,input().split())

C=B-A+1

if K>=C+1:
    print('OK')
elif A%K==0:
    print('OK')
elif B%K==0:
    print('OK')
else:
    print('NG')

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

Verdicts: Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
K=int(input())
A,B=map(int,input().split())
x=A
while x<=B:
  if x%K==0:
    y=100
  else:
    x+=1
    y=0
if y==100:
  print('OK')
else:
  print('No')


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

Verdicts: Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
K = int(input())
A, B = [int(i) for i in input().split()]

if B // K - A // K >= 1:
  print("Yes")
else:
  print("No")


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

if B - A >= K:
  print("Yes")
else:
  print("No")


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

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


Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
a, b, n =  map(int, input().split())
p = 0
for i in range(1, n+1):
  if p < (a*i)//b - a*(i//b):
    p = (a*i)//b - a*(i//b)
print(p)

k = int(input())
a, b = map(int,input().split())
list1 = []
x =(k+a-1)//k
y = b // k

for i in range(x,y+1):
  list1.append(i)
if list1 == []:
  print('NG')
else:
  print('OK')


Verdicts: Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
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)

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)

Verdicts: Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
k = int(input())
a, b = map(int, input().split())

txt = 'No'
tmp = (a // k) * k
if a == tmp or a <= tmp + k <= b:
    txt = 'Yes'

print(txt)


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

txt = 'NG'
tmp = (a // k) * k
if a == tmp or a <= tmp + k <= b:
    txt = 'OK'

print(txt)


Verdicts: Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
X = int(input())

a = 100
i = 0
while a < X:
  a = int(a*1.01)
  i += 1

print(i)

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

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

print('NO')

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

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

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
k = int(input('k: '))
a, b = int(input('a: ')), int(input('b: '))

res = False

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

if res == True:
    print('OK')
else:
    print('NG')

k = int(input('k = '))
a = int(input('a = ')); b = int(input('b = '))

res = False

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

if res == True:
    print('OK')
else:
    print('NG')

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

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
k = int(input())
list = input().split()

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


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


Verdicts: Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
target = int(input())
potential = input().split(" ")
min = int(potential[0])
max = int(potential[1])

can = []
for i in range(min,max+1):
  result = str(i/target)
  if not "." in result:
    can.append(i)
if len(can) != 0:
  print("OK")
else:
  print("NG")

target = int(input())
potential = input().split(" ")
min = int(potential[0])
max = int(potential[1])
 
can = []
for i in range(min,max+1):
  result = str(i/target)
  result = result.split(".")
  if result[1] == "0":
    can.append(i)
if len(can) != 0:
  print("OK")
else:
  print("NG")

Verdicts: Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
K=int(input())
A,B=int(input().split())
check=False
for i in range(0,B-A):
  if (B-A-i)%K==0:
    check=True
if check==True:
  print("OK")
else:
  print("NG")
  

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)

Verdicts: Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
import math
a,b,n = map(int,input().split())
kk = []
for i in range(n):
  kk.append(math.floor(a*n/b)-a*math.floor(n/b))
  n -= 1
print(max(kk))


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

Verdicts: Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
K = int (input ())
A,B = map (int, input ().split ())
X = 'No'
while A <= B:
  if A%K == 0:
    X = 'Yes'
    break
  A += 1
print (X)

K = int (input ())
A,B = map (int, input ().split ())
X = 'NG'
while A <= B:
  if A%K == 0:
    X = 'OK'
    break
  A += 1
print (X)

Verdicts: Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
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)

import math
I = input().split()
A = int(I[0])
B = int(I[1])
N = int(I[2])
def fl(x):
    return math.floor((A*x)/B) - A*math.floor(x/B)

An =fl(N)

if A == 1 and B == 1 :
    An = 0

if B < N :
    for i in range(B,N) :
        if i >= B+1 and fl(i) <= fl(i-1) :
            An = fl(i-1)
            break
elif B == N :
    An = fl(N-1)

print(str(An))

import math
I = input().split()
A = int(I[0])
B = int(I[1])
N = int(I[2])
def fl(x):
    return math.floor((A*x)/B) - A*math.floor(x/B)

An = fl(N)

if A == 1 and B == 1 :
    An = int(0)

if B < N :
    for i in range(B,N) :
        if i >= B+1 and fl(i) <= fl(i-1) :
            An = fl(i-1)
            break
elif B == N :
    An = fl(N-1)

print(str(An))

import math
I = input().split()
A = int(I[0])
B = int(I[1])
N = int(I[2])
def fl(x):
    return math.floor((A*x)/B) - A*math.floor(x/B)

An = fl(N)

if A == 1 : 
    if  B == 1 :
        An = int(0)

if B < N :
    for i in range(B,N) :
        if i >= B+1 and fl(i) <= fl(i-1) :
            An = fl(i-1)
            break
elif B == N :
    An = fl(N-1)

print(str(An))

import math
I = input().split()
A = int(I[0])
B = int(I[1])
N = int(I[2])
def fl(x):
    return math.floor((A*x)/B) - A*math.floor(x/B)

An = fl(N)

if  B == 1 :
    An = int(0)

if B < N :
    for i in range(B,N) :
        if i >= B+1 and fl(i) <= fl(i-1) :
            An = fl(i-1)
            break
elif B == N :
    An = fl(N-1)

print(str(An))

import math
I = input().split()
A = int(I[0])
B = int(I[1])
N = int(I[2])
def fl(x):
    return math.floor((A*x)/B) - A*math.floor(x/B)

if B > N :
    An =fl(N)
else :
    for i in range(B,N) :
        if i >= 2 and fl(i) < fl(i-1) :
            An = fl(i-1)
            break
        else:
            An = fl(N)


print(str(An))

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

la = A%K
lb = B%K

#print(na)
#print(nb)

if na < nb or la == 0 or lb == 0 :
    ans = 'OK'
else:
    ans = 'NG'

print(ans)

Verdicts: Wrong Answer

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: 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`.

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


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

Verdicts: Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
K, A, B = map(int, input().split())
count = 0
for i in range(A, B+1):
    if i % K == 0:
        count += 1
print('OK' if count > 0 else 'NG')

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

Verdicts: Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
k = int(input())
a, b = list(map(int, input().split(' ')))


#     print('OK')

#     print('NG')

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

print('NG')


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


k = int(input())
a, b = list(map(int, input().split(' ')))
res = None

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

print(res)


Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
k = int(input())
a,b = map(int,input().split())

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

import itertools
n,m,q = map(int,input().split())
group = []
for i in range(q):
  w,x,y,z = map(int,input().split())
  v = (w,x,y,z)
  group.append(v)

max_value = max(group[i][3] for i in range(len(group)))



l = [i for i in range(1,m+1)]
h = itertools.combinations_with_replacement(l,n)
array =[]

for v in h:
    array.append(v)



for j in range(len(array)):
  total = 0
  for i in range(q):
    if array[j][group[i][1]-1] - array[j][group[i][0]-1] == group[i][2]:
      total += group[i][3]
  if total >= max_value:
    max_value = total  

print(max_value)

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

Verdicts: Wrong Answer

Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
K=int(input())

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

def m(a,b,c):
	for i in (a, b+1):
  		if i%k==0:
          print("OK")
          return
    print("NG")
    return
m(a,b,k)

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

def m(a,b,c):
    for i in range(a, b+1):
        if i%c==0:
            print("OK")
            return
    print("NG")
    return

m(a,b,k)

Verdicts: Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
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")

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

K=int(input())
A,B=map(int,input().split())
i=0
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")

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

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

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

Verdicts: Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
import sys
from numba import njit
input = sys.stdin.buffer.readline


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


import sys
from numba import njit, i8


@njit(i8(i8), cache=True)
def solve(X):
    money = 100
    res = 0
    while (money < X):
        money *= 1.01
        money = int(money)
        res += 1
    return res


def main():
    input = sys.stdin.buffer.readline
    X: int = int(input())
    print(solve(X))


if __name__ == '__main__':
    main()


import sys

from numba import njit, b1, i8


@njit(b1(i8, i8, i8), cache=True)
def solve(K, A, B):
    for i in range(A, B + 1):
        if i % K == 0:
            return True
    return False


def main():
    input = sys.stdin.buffer.readline
    K = int(input())
    A, B = map(int, input().split())

    print('OK' if solve(K, A, B) else 'NG')


if __name__ == '__main__':
    main()


Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: 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`.

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


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

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

Verdicts: Wrong Answer

Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
k = int(input())
[a,b] = [int(i) for i in input().split()]
f = 0
for i in range(a,b+1):
	if i % k == 0:
    	f = 1
if f:
	print("OK")
else:
	print("NG")

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


Verdicts: Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
l=list(map(int,input().split()))
a=l[0]
b=l[1]
n=l[2]
if b-1<n:
  i=b-1
else:
  i=n
y=(((a*i)/b)//1)-(a*((i/b)//1))
print(int(y))

l=list(map(int,input().split()))
a=l[0]
b=l[1]
n=l[2]
x=0
if b-1<n:
  i=b-1
  y=(((a*i)/b)//1)-(a*((i/b)//1))
else:
  i=n
  y=(((a*i)/b)//1)-(a*((i/b)//1))
print(int(x))

k=int(input())
l=list(map(int,input().split()))
x=l[0]//k
if(x*k==l[0] or k*(x+1)<=l[1]):
  print("OK")
else:
  print("NG")

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: 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`.

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

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

Verdicts: Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
nmq=list(map(int, input().split()))
N=nmq[0]
M=nmq[1]
Q=nmq[2]
ablist=[list(map(int, input().split())) for i in range(Q)]
sumlist=[]
alist=[i for i in range(1,M+1)]
import itertools as ite
case=list(ite.combinations_with_replacement(alist,N))
for nowcase in case:
    sumd=0
    for i in range(Q):
        a=ablist[i][0]
        b=ablist[i][1]
        c=ablist[i][2]
        d=ablist[i][3]
        aa=nowcase[a-1]
        ab=nowcase[b-1]
        if ab-aa==c:
            sumd+=d
    sumlist.append(sumd)
sumlist.sort(reverse=True)
print(sumlist[0])


nmq=list(map(int, input().split()))
N=nmq[0]
M=nmq[1]
Q=nmq[2]
ablist=[list(map(int, input().split())) for i in range(Q)]
sumlist=[]
alist=[i for i in range(1,M+1)]
import itertools as ite
case=list(ite.combinations_with_replacement(alist,N))
for nowcase in case:
    sumd=0
    for i in range(Q):
        a=ablist[i][0]
        b=ablist[i][1]
        c=ablist[i][2]
        d=ablist[i][3]
        aa=nowcase[a-1]
        ab=nowcase[b-1]
        if ab-aa==c:
            sumd+=d
    sumlist.append(sumd)
sumlist.sort(reverse=True)
print(sumlist[0])


nmq=list(map(int, input().split()))
N=nmq[0]
M=nmq[1]
Q=nmq[2]
ablist=[list(map(int, input().split())) for i in range(Q)]
sumlist=[]
alist=[i for i in range(1,M+1)]
import itertools as ite
case=list(ite.combinations_with_replacement(alist,N))
for nowcase in case:
    sumd=0
    for i in range(Q):
        a=ablist[i][0]
        b=ablist[i][1]
        c=ablist[i][2]
        d=ablist[i][3]
        aa=nowcase[a-1]
        ab=nowcase[b-1]
        if ab-aa==c:
            sumd+=d
    sumlist.append(sumd)
print(max(sumlist))


nmq=list(map(int, input().split()))
N=nmq[0]
M=nmq[1]
Q=nmq[2]
ablist=[list(map(int, input().split())) for i in range(Q)]
sumlist=[]
alist=[]
for i in range(1,M+1):
    alist.append(i)
import itertools as ite
case=list(ite.combinations_with_replacement(alist,N))
for nowcase in case:
    sumd=0
    for i in range(Q):
        a=ablist[i][0]
        b=ablist[i][1]
        c=ablist[i][2]
        d=ablist[i][3]
        aa=nowcase[a-1]
        ab=nowcase[b-1]
        if ab-aa==c:
            sumd+=d
    sumlist.append(sumd)
sumlist.sort(reverse=True)
print(sumlist[0])


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


Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
K = int(input("multiple of: "))
A = int(input("From A: "))
B = int(input("To B:"))
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


K = int(input("multiple of: "))
A, B = map(int, input().split())
word = "NG"
for i in range(1, 1000):
    M = K * i
    if M in range(A, B+1):
        word = "OK"
        break
    else: 
        continue
print(word)


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


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


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+1):
        print("OK")
        break
    elif i == 1000 and M not in range(A, B):
        print("NG")
    else: 
        continue


K = int(input("multiple of: "))
A = int(input("From A: "))
B = int(input("To B: "))
word = "NG"
for i in range(A, B+1):
    if i % K == 0:
        word = "OK"
print(word)


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


Verdicts: Runtime Error

Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
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") 

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

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

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

Verdicts: Wrong Answer

Runtime Error

Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
K=int(input())

A,B=(int(x) for x in input().split())

a=A%K

b=K-a

c=A+b

if a!=0:
    if c >= B:
        print('No')
    else:
        print('Yes')
else:
    print('Yes')

K=int(input())

A,B=(int(x) for x in input().split())

a=A%K

b=K-a

c=A+b

if a!=0:
    if c > B:
        print('NG')
    else:
        print('OK')
else:
    print('OK')

Verdicts: Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
import math
 
a,b,n = map(int,input().split())
 
ans = 0
pre = 0
for i in range(1, n+1):
  now = math.floor(a*i / b) - a * math.floor(i / b)
  if now > pre:
    ans = i
    pre = now
  else:
    break
    
print(pre)

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


import math
 
a,b,n = map(int,input().split())
 
ans = 0
pre = 0
for i in range(1, n+1):
  now = math.floor(a*i / b) - a * math.floor(i / b)
  if now > pre:
    ans = i
    pre = now
  elif not now == 0:
    break
    
print(pre)

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

Verdicts: Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
k=int(input())
a,b=map(int,input().split())
for i in range(a,b+1):
  if i%k==0:
    print('OK')
else:
  print('NG')


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

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


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


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

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

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

Verdicts: Wrong Answer

Runtime Error

Wrong Answer

Wrong Answer

Wrong Answer

Wrong Answer

Accepted
Problem: 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`.

Submission attempts (in order):
a, b = [int(x) for x in input().split()]
k = int(input())
found = False
for i in range(a, b + 1):
    if i % k == 0:
        found = True
if found: 
    print("YES")
else:
    print("NO")
    

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


Verdicts: Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
K=input()
A,B = map(int,input().split())

sa = B - A 
flag = 0

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

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

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

sa = B - A 
flag = 0

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

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

Verdicts: Runtime Error

Accepted
Problem: 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`.

Submission attempts (in order):
k = int(input())
a, b = [int(x) for x in input()]
res = a//k < b//k or not a%k or not b%k
print('OK' if res else 'NG')

k = int(input())
a, b = [int(x) for x in input()]
res = a//k < b//k or not a%k not b%k
print('OK' if res else 'NG')

import sys

k, tmp = [line.rstrip() for line in sys.stdin]
k, a, b = int(k), [int(x) for x in tmp.split()]
print(a//k < b//k)

k = int(input())
a, b = [int(x) for x in input().split()]
res = (a//k < b//k) or (not a%k) or (not b%k)
print('OK' if res else 'NG')

Verdicts: Runtime Error

Runtime Error

Runtime Error

Accepted