buggy_code stringlengths 11 625k | fixed_code stringlengths 17 625k | bug_type stringlengths 2 4.45k | language int64 0 8 | token_count int64 5 200k |
|---|---|---|---|---|
k = int(input())
a, b = map(int, input().split())
c = 0
for i in range(a,b+1):
if i == k:
c += 1
if (c == 0):
print('NG')
else:
print('OK') | k = int(input())
a, b = map(int, input().split())
c = 0
for i in range(a,b+1):
if i % k == 0:
c += 1
if (c == 0):
print('NG')
else:
print('OK') | [["-", 0, 7, 8, 196, 0, 57, 15, 666, 667, 60], ["+", 8, 196, 0, 57, 15, 666, 0, 657, 17, 109], ["+", 0, 7, 8, 196, 0, 57, 15, 666, 667, 60], ["+", 0, 7, 8, 196, 0, 57, 15, 666, 0, 612]] | 5 | 68 |
# -*- 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")
| # -*- coding: utf-8 -*-
k = int(input())
a, b = map(int, input().split())
if k==1:
print("OK")
elif a%k == 0:
print("OK")
elif abs(a-b) + a%k >= k:
print("OK")
# elif a//k != b//k:
# print("OK")
else:
print("NG")
| [["-", 0, 57, 75, 665, 15, 666, 0, 657, 17, 33], ["-", 0, 57, 75, 665, 15, 666, 0, 657, 12, 612]] | 5 | 81 |
#include <cmath>
#include <iostream>
#include <stdlib.h>
int main() {
int a, b, k, i, s = 0;
std::cin >> k;
std::cin >> a >> b;
for (i = a; i <= b; i++) {
if (i % k == 0)
s++;
}
if (s == 0)
std::cout << "ng";
else
std::cout << "ok";
return 0;
}
| #include <cmath>
#include <iostream>
#include <stdlib.h>
int main() {
int a, b, k, i, s = 0;
std::cin >> k;
std::cin >> a >> b;
for (i = a; i <= b; i++) {
if (i % k == 0)
s++;
}
if (s == 0)
std::cout << "NG";
else
std::cout << "OK";
return 0;
}
| [["-", 0, 57, 64, 1, 0, 16, 12, 5, 0, 6], ["+", 0, 57, 64, 1, 0, 16, 12, 5, 0, 6], ["-", 75, 76, 0, 1, 0, 16, 12, 5, 0, 6], ["+", 75, 76, 0, 1, 0, 16, 12, 5, 0, 6]] | 1 | 91 |
k=int(input())
a,b=map(int,input().split())
i=b%k
if i==0:
print('OK')
else:
if a < b-i:
print('OK')
else:
print('NG') | k=int(input())
a,b=map(int,input().split())
i=b%k
if i==0:
print('OK')
else:
if a <= b-i:
print('OK')
else:
print('NG') | [["-", 75, 76, 8, 196, 0, 57, 15, 666, 667, 18], ["+", 75, 76, 8, 196, 0, 57, 15, 666, 667, 19]] | 5 | 63 |
#include <iostream>
using namespace std;
int main() {
int K, A, B;
cin >> K >> A >> B;
int L = A % K;
if (L == 0 || ((L * K) + K) <= B) {
cout << "OK" << endl;
} else {
cout << "NG" << endl;
}
return 0;
}
| #include <iostream>
using namespace std;
int main() {
int K, A, B;
cin >> K >> A >> B;
int L = A % K;
if (L == 0 || ((A / K) * K + K) <= B) {
cout << "OK" << endl;
} else {
cout << "NG" << endl;
}
return 0;
}
| [["-", 31, 23, 0, 16, 31, 23, 0, 16, 31, 22], ["-", 31, 23, 0, 16, 31, 23, 0, 16, 17, 48], ["+", 0, 16, 31, 16, 31, 23, 0, 16, 31, 22], ["+", 0, 16, 31, 16, 31, 23, 0, 16, 17, 85], ["+", 12, 16, 31, 23, 0, 16, 31, 16, 17, 48], ["+", 12, 16, 31, 23, 0, 16, 31, 16, 12, 22]] | 1 | 76 |
#include <bits/stdc++.h>
#define lint long long int
#define sudo std::
#define girdi freopen("motor.gir", "r", stdin);
#define cikti freopen("motor.cik", "w", stdout);
#define faster \
ios_base::sync_with_stdio(0); ... | #include <bits/stdc++.h>
#define lint long long int
#define sudo std::
#define girdi freopen("motor.gir", "r", stdin);
#define cikti freopen("motor.cik", "w", stdout);
#define faster \
ios_base::sync_with_stdio(0); ... | [["+", 31, 23, 0, 16, 31, 2, 63, 23, 0, 24], ["+", 15, 339, 51, 16, 31, 16, 31, 23, 0, 25], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 48], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 22]] | 1 | 311 |
k = int(input())
a, b = list(map(int, input().split()))
for i in range(1000):
if a<= k*i <= b :
print("OK")
exit()
else :
print("NG")
| k = int(input())
a, b = list(map(int, input().split()))
for i in range(1000):
if a<= k*i <=b :
print("OK")
exit()
print("NG")
| [["-", 0, 7, 8, 196, 0, 57, 75, 76, 0, 95], ["-", 0, 7, 8, 196, 0, 57, 75, 76, 0, 102]] | 5 | 61 |
def main():
K = int(input())
A, B = map(int, input().split())
for i in range(A, B):
if i%K == 0:
print("OK")
exit()
print("NG")
main() | def main():
K = int(input())
A, B = map(int, input().split())
for i in range(A, B+1):
if i%K == 0:
print("OK")
exit()
print("NG")
main() | [["+", 0, 7, 12, 652, 3, 4, 0, 657, 17, 72], ["+", 0, 7, 12, 652, 3, 4, 0, 657, 12, 612]] | 5 | 64 |
A = int(input())
B, C = map(int,input().split())
flag = 1
for i in range(B, C):
if i % A == 0:
flag = 0
print("OK")
break
if flag==1:
print("NG")
| A = int(input())
B, C = map(int,input().split())
flag = 1
for i in range(B, C+1):
if i % A == 0:
flag = 0
print("OK")
break
if flag==1:
print("NG")
| [["+", 0, 7, 12, 652, 3, 4, 0, 657, 17, 72], ["+", 0, 7, 12, 652, 3, 4, 0, 657, 12, 612]] | 5 | 65 |
k=gets.to_i
a,b=gets.split.map &:to_i
nums = [*(a..b)]
nums.each do |num|
b = true if num%k == 0
end
p b == true ? 'OK' : 'NG' | k=gets.to_i
a,b=gets.split.map &:to_i
nums = [*(a..b)]
nums.each do |num|
b = true if num%k == 0
end
puts b == true ? 'OK' : 'NG' | [["-", 36, 36, 36, 36, 0, 493, 0, 652, 735, 22], ["+", 36, 36, 36, 36, 0, 493, 0, 652, 735, 22]] | 4 | 55 |
#include <stdio.h>
int main() {
int k;
int a, b;
int i;
scanf("%d", &k);
scanf("%d %d", &a, &b);
for (i = a; i <= b; i++) {
if (i % k == 0) {
printf("ok");
break;
}
if (i == b) {
printf("no");
}
}
} | #include <stdio.h>
int main() {
int k;
int a, b;
int i;
scanf("%d", &k);
scanf("%d %d", &a, &b);
for (i = a; i <= b; i++) {
if (i % k == 0) {
printf("OK");
break;
}
if (i == b) {
printf("NG");
}
}
} | [["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6]] | 0 | 91 |
#include <stdio.h>
int main(void) {
int i, j;
int a, b, k, c, d;
scanf("%d", &k);
scanf("%d", &a);
scanf("%d", &b);
c = a / k;
d = b / k;
if (c == d) {
printf("OK\n");
} else if (a % k == 0) {
printf("OK\n");
} else {
printf("NG\n");
}
return 0;
} | #include <stdio.h>
int main(void) {
int i, j;
int a, b, k, c, d;
scanf("%d", &k);
scanf("%d", &a);
scanf("%d", &b);
c = a / k;
d = b / k;
if (c < d) {
printf("OK\n");
} else if (a % k == 0) {
printf("OK\n");
} else {
printf("NG\n");
}
return 0;
} | [["-", 8, 9, 0, 57, 15, 23, 0, 16, 17, 60], ["+", 8, 9, 0, 57, 15, 23, 0, 16, 17, 18]] | 0 | 116 |
K = int(input())
A, B = map(int, input().split())
num =A
while A <= num <= B:
if num % K == 0:
x="OK"
break
else:
x="NG"
A +=1
print(x) | K = int(input())
A, B = map(int, input().split())
num =A
while A <= num <= B:
if num % K == 0:
x="OK"
break
else:
x="NG"
num +=1
print(x) | [["-", 75, 76, 8, 196, 0, 1, 0, 677, 31, 22], ["+", 75, 76, 8, 196, 0, 1, 0, 677, 31, 22]] | 5 | 61 |
#include <bits/stdc++.h>
using namespace std;
int main() {
int K, A, B;
cin >> K >> A >> B;
if (K == 1) {
cout << "OK" << endl;
} else if (A % K == 0 || B % K == 0) {
cout << "OK" << endl;
} else if (B / K >> A / K) {
cout << "OK" << endl;
} else {
cout << "NG" << endl;
}
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
int K, A, B;
cin >> K >> A >> B;
if (K == 1) {
cout << "OK" << endl;
} else if (A % K == 0 || B % K == 0) {
cout << "OK" << endl;
} else if (B / K != A / K) {
cout << "OK" << endl;
} else {
cout << "NG" << endl;
}
}
| [["-", 75, 76, 0, 57, 15, 339, 51, 16, 17, 152], ["+", 75, 76, 0, 57, 15, 339, 51, 16, 17, 79]] | 1 | 100 |
#include <bits/stdc++.h>
using namespace std;
int main() {
int K, A, B;
cin >> K >> A >> B;
bool C = false;
if (A != B) {
for (int i = 0; i < (B - A); i++) {
if ((i + A) % K == 0) {
C = true;
break;
}
}
} else {
if (A % K == 0) {
C = true;
}
}
if (C == tru... | #include <bits/stdc++.h>
using namespace std;
int main() {
int K, A, B;
cin >> K >> A >> B;
bool C = false;
if (A != B) {
for (int i = 0; i < (B - A + 1); i++) {
if ((i + A) % K == 0) {
C = true;
break;
}
}
} else {
if (A % K == 0) {
C = true;
}
}
if (C ==... | [["+", 0, 7, 15, 16, 12, 23, 0, 16, 17, 72], ["+", 0, 7, 15, 16, 12, 23, 0, 16, 12, 13]] | 1 | 124 |
#include <algorithm>
#include <bits/stdc++.h>
using namespace std;
int main() {
int K, A, B;
cin >> K;
cin >> A, B;
for (int i = A; i <= B; i++) {
if (i % K == 0) {
cout << "OK" << endl;
return 0;
}
}
cout << "NG" << endl;
} | #include <algorithm>
#include <bits/stdc++.h>
using namespace std;
int main() {
int K, A, B;
cin >> K;
cin >> A >> B;
for (int i = A; i <= B; i++) {
if (i % K == 0) {
cout << "OK" << endl;
return 0;
}
}
cout << "NG" << endl;
} | [["-", 0, 14, 8, 9, 0, 1, 0, 34, 0, 21], ["+", 0, 14, 8, 9, 0, 1, 0, 16, 17, 152]] | 1 | 76 |
#include <stdio.h>
int main(void) {
int K = 0, A = 0, B = 0, a = 0, b = 0, c = 0, d = 0;
scanf("%d %d %d", &K, &A, &B);
a = A / K;
b = B / K;
c = A % K;
d = B % K;
if (c == 0) {
printf("ok");
}
else {
if (d == 0) {
printf("ok");
} else {
if ((b - a) > 0) {
printf("... | #include <stdio.h>
int main(void) {
int K = 0, A = 0, B = 0, a = 0, b = 0, c = 0, d = 0;
scanf("%d %d %d", &K, &A, &B);
a = A / K;
b = B / K;
c = A % K;
d = B % K;
if (c == 0) {
printf("OK");
}
else {
if (d == 0) {
printf("OK");
} else {
if ((b - a) > 0) {
printf("... | [["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6]] | 0 | 146 |
#include <iostream>
using namespace std;
int main(void) {
long K, A, B;
long mod_A, mod_B;
cin >> K;
cin >> A >> B;
mod_A = A % K;
mod_B = B % K;
if (mod_B - mod_A < K) {
if ((mod_A == 0) || (mod_B == 0)) {
cout << "OK";
} else if (mod_A > mod_B) {
cout << "OK";
} else {
... | #include <iostream>
using namespace std;
int main(void) {
int K, A, B;
int mod_A, mod_B;
cin >> K;
cin >> A >> B;
mod_A = A % K;
mod_B = B % K;
if (B - A < K) {
if ((mod_A == 0) || (mod_B == 0)) {
cout << "OK";
} else if (mod_A > mod_B) {
cout << "OK";
} else {
cout << "N... | [["-", 0, 14, 8, 9, 0, 43, 39, 86, 0, 96], ["+", 0, 30, 0, 14, 8, 9, 0, 43, 39, 40], ["-", 0, 57, 15, 339, 51, 16, 31, 16, 31, 22], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 31, 22], ["-", 0, 57, 15, 339, 51, 16, 31, 16, 12, 22], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 22]] | 1 | 112 |
#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (n); ++i)
using namespace std;
using ll = long long;
int main() {
int k;
cin >> k;
int a, b;
cin >> a >> b;
bool ans = false;
for (int i = a; i < b + 1; ++i) {
if (i % k == 0)
ans = true;
break;
}
if (ans)
cout << "OK" << ... | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (n); ++i)
using namespace std;
using ll = long long;
int main() {
int k;
cin >> k;
int a, b;
cin >> a >> b;
bool ans = false;
for (int i = a; i < b + 1; ++i) {
if (i % k == 0) {
ans = true;
break;
}
}
if (ans)
cout <... | [["+", 0, 7, 8, 9, 0, 57, 64, 9, 0, 45], ["+", 0, 7, 8, 9, 0, 57, 64, 9, 0, 46]] | 1 | 105 |
#include <bits/stdc++.h>
using namespace std;
int main() {
int k, a, b;
cin >> k;
cin >> a >> b;
b = b / k;
a = a / k;
if (b - a >= 1) {
cout << "OK" << endl;
} else {
cout << "NG" << endl;
}
} | #include <bits/stdc++.h>
using namespace std;
int main() {
int k, a, b;
cin >> k;
cin >> a >> b;
b = b / k;
a -= 1;
a = a / k;
if (b - a >= 1) {
cout << "OK" << endl;
} else {
cout << "NG" << endl;
}
} | [["+", 0, 14, 8, 9, 0, 1, 0, 11, 17, 110], ["+", 0, 14, 8, 9, 0, 1, 0, 11, 12, 13], ["+", 0, 30, 0, 14, 8, 9, 0, 1, 0, 35], ["+", 0, 14, 8, 9, 0, 1, 0, 11, 31, 22]] | 1 | 70 |
#include <iostream>
using namespace std;
int main() {
int k, a, b;
cin >> k >> a >> b;
bool he = false;
for (int i = a; i <= b; i++) {
if (i % k == 0) {
cout << "YES";
he = true;
break;
}
}
if (!he) {
cout << "NO";
}
}
| #include <iostream>
using namespace std;
int main() {
int k, a, b;
cin >> k >> a >> b;
bool he = false;
for (int i = a; i <= b; i++) {
if (i % k == 0) {
cout << "OK";
he = true;
break;
}
}
if (!he) {
cout << "NG";
}
} | [["-", 64, 9, 0, 1, 0, 16, 12, 5, 0, 6], ["+", 64, 9, 0, 1, 0, 16, 12, 5, 0, 6]] | 1 | 83 |
#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < n; ++i)
using namespace std;
#define int long long
#define double long double
int check(int a, int b, int x) { return a * x / b - a * (x / b); }
main(void) {
int a, b, c;
cin >> a >> b >> c;
int d = b / a;
int e = a * (d + 1);
if (e <= c || d == b... | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < n; ++i)
using namespace std;
#define int long long
#define double long double
int check(int a, int b, int x) { return a * x / b - a * (x / b); }
main(void) {
int a, b, c;
cin >> a >> b >> c;
int d = b / a;
int e = a * (d + 1);
if (e <= c || (d * a... | [["+", 15, 339, 51, 16, 12, 16, 31, 23, 0, 24], ["+", 51, 16, 12, 16, 31, 23, 0, 16, 17, 48], ["+", 51, 16, 12, 16, 31, 23, 0, 16, 12, 22], ["+", 15, 339, 51, 16, 12, 16, 31, 23, 0, 25]] | 1 | 119 |
a=int(input())
n,m=map(int,input().split())
if a==1:
print('OK')
else:
c=0
b=m-n
for i in range(b):
if (m-i)%a==0:
c+=1
break
if c==0:
print('NG')
else:
print('OK')
| a=int(input())
n,m=map(int,input().split())
if a==1:
print('OK')
else:
c=0
b=m-n
for i in range(b+1):
if (m-i)%a==0:
c+=1
break
if c==0:
print('NG')
else:
print('OK')
| [["+", 0, 7, 12, 652, 3, 4, 0, 657, 17, 72], ["+", 0, 7, 12, 652, 3, 4, 0, 657, 12, 612]] | 5 | 87 |
K=int(input())
A,B=map(int,input().split())
L=[]
for i in range(A,B):
L.append(i%K)
if 0 in L:
print("OK")
else:
print("NG") | K=int(input())
A,B=map(int,input().split())
L=[]
for i in range(A,B+1):
L.append(i%K)
if 0 in L:
print("OK")
else:
print("NG")
| [["+", 0, 7, 12, 652, 3, 4, 0, 657, 17, 72], ["+", 0, 7, 12, 652, 3, 4, 0, 657, 12, 612]] | 5 | 65 |
G = int(input())
A, B = map(int,input().split())
Total = 'OK'
for i in range(A,B+1):
if i% G != 0:
Total = 'NG'
print(Total) | G = int(input())
A, B = map(int,input().split())
Total = 'NG'
for i in range(A,B+1):
if i% G == 0:
Total = 'OK'
print(Total) | [["-", 0, 656, 0, 1, 0, 662, 12, 557, 0, 6], ["+", 0, 656, 0, 1, 0, 662, 12, 557, 0, 6], ["-", 0, 7, 8, 196, 0, 57, 15, 666, 667, 79], ["+", 0, 7, 8, 196, 0, 57, 15, 666, 667, 60], ["-", 64, 196, 0, 1, 0, 662, 12, 557, 0, 6], ["+", 64, 196, 0, 1, 0, 662, 12, 557, 0, 6]] | 5 | 57 |
import sys
input = sys.stdin.readline
k = int(input())
a, b = map(int, input().split())
c = b//k
if k == 1:
print("OK")
else:
if c * k >a:
print("OK")
else:
print("NG")
| import sys
input = sys.stdin.readline
k = int(input())
a, b = map(int, input().split())
c = b//k
if k == 1:
print("OK")
else:
if c * k >=a:
print("OK")
else:
print("NG")
| [["-", 75, 76, 8, 196, 0, 57, 15, 666, 667, 47], ["+", 75, 76, 8, 196, 0, 57, 15, 666, 667, 20]] | 5 | 72 |
k = int(input())
a, b = [int(x) for x in input().split()]
result = False
check = [x*k for x in range(0, 1000)]
for i in check:
if (i > a and i < b):
result = True
else:
continue
if result:
print('OK')
else:
print('NG') | k = int(input())
a, b = [int(x) for x in input().split()]
result = False
check = [x*k for x in range(0, 1000)]
for i in check:
if (i >= a and i <= b):
result = True
else:
continue
if result:
print('OK')
else:
print('NG') | [["-", 0, 57, 15, 23, 0, 679, 31, 666, 667, 47], ["+", 0, 57, 15, 23, 0, 679, 31, 666, 667, 20], ["-", 0, 57, 15, 23, 0, 679, 12, 666, 667, 18], ["+", 0, 57, 15, 23, 0, 679, 12, 666, 667, 19]] | 5 | 86 |
#include <bits/stdc++.h>
using namespace std;
int main() {
int K, A, B;
cin >> K >> A >> B;
if (B - A >= K) {
cout << "OK" << endl;
} else if (A == B && A % K == 0) {
cout << "OK" << endl;
} else if (A % K >= B % K || A % K == 0) {
cout << "OK" << endl;
} else {
cout << "NG" << endl;
}
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
int K, A, B;
cin >> K >> A >> B;
if (B - A >= K) {
cout << "OK" << endl;
} else if (A == B && A % K == 0) {
cout << "OK" << endl;
} else if (A % K > B % K || A % K == 0) {
cout << "OK" << endl;
} else {
cout << "NG" << endl;
}
}
| [["-", 0, 57, 15, 339, 51, 16, 31, 16, 17, 20], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 47]] | 1 | 106 |
import java.util.*;
class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int k = sc.nextInt();
int a = sc.nextInt();
int b = sc.nextInt();
String result = "NG";
for (int i = a - 1; i <= b; i++) {
if (i % k == 0) {
result = "OK";
brea... | import java.util.*;
class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int k = sc.nextInt();
int a = sc.nextInt();
int b = sc.nextInt();
String result = "NG";
for (int i = a; i <= b; i++) {
if (i % k == 0) {
result = "OK";
break;
... | [["-", 0, 7, 502, 503, 49, 200, 51, 16, 17, 33], ["-", 0, 7, 502, 503, 49, 200, 51, 16, 12, 499]] | 3 | 113 |
k=int(input())
a, b=map(int, input().split())
c = True
for i in range(a, b+1):
if i%k ==0:
print(OK)
c = False
break
if c:
print(NG)
| k=int(input())
a, b=map(int, input().split())
c = True
for i in range(a, b+1):
if i%k ==0:
print("OK")
c = False
break
if c:
print("NG") | [["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 654], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 655]] | 5 | 61 |
N = int(input())
L= list(map(int,input().split()))
min = L[0]
max = L[1]
for i in range(min,max):
if i % N == 0:
print("OK")
break
else:
print("NG")
| N = int(input())
L= list(map(int,input().split()))
min = L[0]
max = L[1]
for i in range(min,max+1):
if i % N == 0:
print("OK")
break
else:
print("NG")
| [["+", 0, 7, 12, 652, 3, 4, 0, 657, 17, 72], ["+", 0, 7, 12, 652, 3, 4, 0, 657, 12, 612]] | 5 | 69 |
#include <iostream>
using namespace std;
int main() {
int n, a, b;
cin >> n >> a >> b;
int flag = 0;
for (int i = a; i <= b; i++) {
if (i % n == 0) {
flag = 1;
break;
}
}
if (flag == 0)
cout << "OK" << endl;
else
cout << "NG" << endl;
} | #include <iostream>
using namespace std;
int main() {
int n, a, b;
cin >> n >> a >> b;
int flag = 0;
for (int i = a; i <= b; i++) {
if (i % n == 0) {
flag = 1;
break;
}
}
if (flag == 0)
cout << "NG" << endl;
else
cout << "OK" << endl;
} | [["-", 64, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["+", 64, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["-", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["+", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6]] | 1 | 87 |
k = gets.to_i
a,b = gets.split.map(&:to_i)
num = 0
while (num <= b) do
if num % k == 0 && a <= num && num <= b
return puts "OK"
end
num += k
puts num
end
puts "NG" | k = gets.to_i
a,b = gets.split.map(&:to_i)
num = 0
while (num <= b) do
if num % k == 0 && a <= num && num <= b
return puts "OK"
end
num += k
end
puts "NG" | [["-", 0, 493, 0, 89, 8, 170, 0, 652, 735, 22], ["-", 0, 89, 8, 170, 0, 652, 3, 4, 0, 22]] | 4 | 58 |
K = int(input())
A, B = map(int, input().split())
if A % K == 0:
print('OK')
elif B % K == 0:
print('OK')
elif A <= K and K <= B:
print('OK')
elif K * ((A // K) + 1) <= B:
print('OK')
else:
print('No') | K = int(input())
A, B = map(int, input().split())
if A % K == 0:
print('OK')
elif B % K == 0:
print('OK')
elif A <= K and K <= B:
print('OK')
elif K * ((A // K) + 1) <= B:
print('OK')
else:
print('NG') | [["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6]] | 5 | 94 |
#include <iostream>
using namespace std;
int main() {
int k, a, b, i, cnt = 0;
cin >> k >> a >> b;
for (i = a + 1; i <= b; i++) {
if (i % k == 0) {
cnt++;
break;
}
}
if (cnt == 0) {
cout << "NG";
} else
cout << "OK";
return 0;
} | #include <iostream>
using namespace std;
int main() {
int k, a, b, i, cnt = 0;
cin >> k >> a >> b;
// if(a!=b){
for (i = a; i <= b; i++) {
if (i % k == 0) {
cnt++;
break;
}
}
// else{if(a%k==0) {cnt++;
//}
//}
if (cnt == 0) {
cout << "NG";
} else
cout << "OK";
return 0... | [["-", 8, 9, 0, 7, 10, 11, 12, 16, 17, 72], ["-", 8, 9, 0, 7, 10, 11, 12, 16, 12, 13]] | 1 | 89 |
import math
k = int(input())
a,b = map(int,input().split())
if math.floor(b/k) - math.floor(a/k) > 0 or k == 1:
print("OK")
else:
print("NG") | import math
k = int(input())
a,b = map(int,input().split())
if math.floor(b/k) - math.floor(a/k) > 0 or a % k == 0:
print("OK")
else:
print("NG") | [["+", 0, 57, 15, 679, 12, 666, 0, 657, 31, 22], ["+", 0, 57, 15, 679, 12, 666, 0, 657, 17, 109], ["-", 0, 656, 0, 57, 15, 679, 12, 666, 0, 612], ["+", 0, 656, 0, 57, 15, 679, 12, 666, 0, 612]] | 5 | 65 |
# Author : devil9614 - Sujan Mukherjee
from __future__ import division, print_function
import os,sys
import math
import collections
from io import BytesIO, IOBase
if sys.version_info[0] < 3:
from __builtin__ import xrange as range
from future_builtins import ascii, filter, hex, map, oct, zip
def ii(): ret... |
# Author : devil9614 - Sujan Mukherjee
from __future__ import division, print_function
import os,sys
import math
import collections
from io import BytesIO, IOBase
if sys.version_info[0] < 3:
from __builtin__ import xrange as range
from future_builtins import ascii, filter, hex, map, oct, zip
def ii(): ret... | [["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6]] | 5 | 1,550 |
int main() {
int a;
int s, t;
scanf("%d%d%d", &a, &s, &t);
for (int i = s; i <= t; i++) {
if (i % a == 0) {
printf("OK");
return 0;
} else if (i == t) {
printf("No");
return 0;
}
}
} | int main() {
int a;
int s, t;
scanf("%d%d%d", &a, &s, &t);
for (int i = s; i <= t; i++) {
if (i % a == 0) {
printf("OK");
return 0;
} else if (i == t) {
printf("NG");
return 0;
}
}
} | [["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6]] | 0 | 85 |
#include <algorithm>
#include <cmath>
#include <cstdio>
#include <cstring>
#include <ctime>
#include <iostream>
#include <map>
#include <queue>
#include <string>
using namespace std;
template <typename T>
inline T read() {
T x = 0, f = 1;
char c = getchar();
while (!isdigit(c)) {
if (c == '-')
f = -f... | #include <algorithm>
#include <cmath>
#include <cstdio>
#include <cstring>
#include <ctime>
#include <iostream>
#include <map>
#include <queue>
#include <string>
using namespace std;
template <typename T>
inline T read() {
T x = 0, f = 1;
char c = getchar();
while (!isdigit(c)) {
if (c == '-')
f = -f... | [["-", 0, 1, 0, 2, 3, 4, 0, 66, 28, 22], ["+", 0, 1, 0, 2, 3, 4, 0, 66, 28, 22]] | 1 | 219 |
#include <algorithm>
#include <cctype>
#include <iostream>
#include <string>
#include <vector>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
typedef long long ll;
int main() {
int k, a, b;
cin >> k;
cin >> a >> b;
int ans = 1;
for (int i = a; i <= b; i++) {
if (i % k == 0) {
... | #include <algorithm>
#include <cctype>
#include <iostream>
#include <string>
#include <vector>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
typedef long long ll;
int main() {
int k, a, b;
cin >> k;
cin >> a >> b;
int ans = 1;
for (int i = a; i <= b; i++) {
if (i % k == 0) {
... | [["-", 64, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["+", 64, 1, 0, 16, 31, 16, 12, 5, 0, 6]] | 1 | 110 |
n = int(input())
b,c=map(int, input().split())
k = b
while b<= k <= c :
if k % n == 0 :
print('OK')
exit()
b = b +1
print('NG') | n = int(input())
b,c=map(int, input().split())
k = b
while b<= k <= c :
if k % n == 0 :
print('OK')
exit()
k += 1
print('NG') | [["-", 0, 52, 8, 196, 0, 1, 0, 662, 31, 22], ["-", 0, 52, 8, 196, 0, 1, 0, 662, 0, 32], ["-", 8, 196, 0, 1, 0, 662, 12, 657, 31, 22], ["-", 8, 196, 0, 1, 0, 662, 12, 657, 17, 72], ["+", 0, 52, 8, 196, 0, 1, 0, 677, 31, 22], ["+", 0, 52, 8, 196, 0, 1, 0, 677, 17, 107]] | 5 | 61 |
k=gets.chomp.to_f
a,b=gets.chomp.split(" ").map{|i|i.to_i}
res = ""
a.upto(b) do |i|
if i % k == 0
res = "ok"
break
else
res = "NG"
end
end
puts res
| k=gets.chomp.to_i
a,b=gets.chomp.split(" ").map{|i|i.to_i}
res = ""
a.upto(b) do |i|
if i % k == 0
res = "OK"
break
else
res = "NG"
end
end
puts res | [["-", 36, 36, 0, 493, 0, 662, 12, 652, 735, 22], ["+", 36, 36, 0, 493, 0, 662, 12, 652, 735, 22], ["-", 0, 121, 64, 749, 0, 662, 12, 557, 0, 6], ["+", 0, 121, 64, 749, 0, 662, 12, 557, 0, 6]] | 4 | 67 |
#include <bits/stdc++.h>
using namespace std;
#define endl "\n"
#define PB push_back
#define F first
#define S second
#define int long long
#define Runner_up \
ios_base::sync_with_stdio(0); \
cin.tie(0); ... |
#include <bits/stdc++.h>
using namespace std;
#define endl "\n"
#define PB push_back
#define F first
#define S second
#define int long long
#define Runner_up \
ios_base::sync_with_stdio(0); \
cin.tie(0); ... | [["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 18], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 19]] | 1 | 111 |
#include <iostream>
using namespace std;
int main() {
int K, A, B;
cin >> K >> A >> B;
int kakeru = A / K;
if (A % K != 0)
kakeru++;
if (K * kakeru <= B)
cout << "Yes";
else
cout << "No";
return 0;
} | #include <iostream>
using namespace std;
int main() {
int K, A, B;
cin >> K >> A >> B;
int kakeru = A / K;
if (A % K != 0)
kakeru++;
if (K * kakeru <= B)
cout << "OK";
else
cout << "NG";
return 0;
} | [["-", 0, 57, 64, 1, 0, 16, 12, 5, 0, 6], ["+", 0, 57, 64, 1, 0, 16, 12, 5, 0, 6], ["-", 75, 76, 0, 1, 0, 16, 12, 5, 0, 6], ["+", 75, 76, 0, 1, 0, 16, 12, 5, 0, 6]] | 1 | 69 |
#include <bits/stdc++.h>
using namespace std;
#define pi 3.14159265359
int main() {
int K, A, B;
cin >> K;
cin >> A >> B;
int a = A * K;
int b = B * K;
int c = A % K;
int d = B % K;
if (b > a)
cout << "OK" << endl;
else {
if (c == 0 || d == 0) {
cout << "OK" << endl;
}
else {... | #include <bits/stdc++.h>
using namespace std;
#define pi 3.14159265359
int main() {
int K, A, B;
cin >> K;
cin >> A >> B;
int a = A / K;
int b = B / K;
int c = A % K;
int d = B % K;
if (b > a)
cout << "OK" << endl;
else {
if (c == 0 || d == 0) {
cout << "OK" << endl;
}
else {... | [["-", 8, 9, 0, 43, 49, 50, 51, 16, 17, 48], ["+", 8, 9, 0, 43, 49, 50, 51, 16, 17, 85]] | 1 | 108 |
#include <bits/stdc++.h>
using namespace std;
int main() {
int K, A, B;
cin >> K;
cin >> A >> B;
int wallA;
wallA = A / K;
if ((wallA + 1) * K <= B || A == K) {
cout << "OK" << endl;
} else {
cout << "NG" << endl;
}
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
int K, A, B;
cin >> K;
cin >> A >> B;
int wallA;
wallA = A / K;
if ((wallA + 1) * K <= B || A == wallA * K) {
cout << "OK" << endl;
} else {
cout << "NG" << endl;
}
}
| [["+", 15, 339, 51, 16, 12, 16, 12, 16, 31, 22], ["+", 15, 339, 51, 16, 12, 16, 12, 16, 17, 48]] | 1 | 75 |
K= int(input())
A,B=map(int,input().split())
s= int(A/K)
if s*K==A:
print("OK")
elif (s+1)*K>B:
print("NG")
else:
print("NG")
| K= int(input())
A,B=map(int,input().split())
s= int(A/K)
if s*K==A:
print("OK")
elif (s+1)*K>B:
print("NG")
else:
print("OK")
| [["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6]] | 5 | 70 |
#include <stdio.h>
int main(void) {
int k, a, b;
int tf = 0;
scanf("%d", &k);
scanf("%d %d", &a, &b);
if (scanf("%d", &k) != 0 && scanf("%d %d", &a, &b) != 0) {
for (int i = 0; k * i < b; i++) {
if ((a <= k * i) && (k * i <= b)) {
tf = 1;
break;
}
}
if (tf == 0) {
... | #include <stdio.h>
int main(void) {
int k, a, b;
int tf = 0;
scanf("%d", &k);
scanf("%d %d", &a, &b);
if (scanf("%d", &k) != 0 && scanf("%d %d", &a, &b) != 0) {
for (int i = 0; k * i <= b; i++) {
if ((a <= k * i) && (k * i <= b)) {
tf = 1;
break;
}
}
if (tf == 0) {
... | [["-", 0, 57, 64, 9, 0, 7, 15, 16, 17, 18], ["+", 0, 57, 64, 9, 0, 7, 15, 16, 17, 19]] | 0 | 147 |
K = int(input())
A, B = map(int,input().split())
tmp = A % k
if(tmp == 0):
print('OK')
else:
if(A + (K-tmp) <= B):
print('OK')
else:
print('NG') | K = int(input())
A, B = map(int,input().split())
tmp = A % K
if(tmp == 0):
print('OK')
else:
if(A + (K-tmp) <= B):
print('OK')
else:
print('NG') | [["-", 0, 656, 0, 1, 0, 662, 12, 657, 12, 22], ["+", 0, 656, 0, 1, 0, 662, 12, 657, 12, 22]] | 5 | 71 |
K=int(input())
A,B = map(int, input().split())
count=0
for i in range(A,B+1):
if i%K==0:
print("OK")
count+=1
if count==0:
print("NG")
| K=int(input())
A,B = map(int, input().split())
count=0
for i in range(A,B+1):
if i%K==0:
print("OK")
count+=1
break
if count==0:
print("NG") | [["+", 8, 196, 0, 57, 64, 196, 0, 93, 0, 94]] | 5 | 66 |
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner scan = new Scanner(System.in);
int K = scan.nextInt(); //倍数
int A = scan.nextInt(); //最低値
int B = scan.nextInt(); //最高値
String ans = "NG";
for (int i = A; i >= B; i++) {
if (i % K == 0) {
... | import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner scan = new Scanner(System.in);
int K = scan.nextInt(); //倍数
int A = scan.nextInt(); //最低値
int B = scan.nextInt(); //最高値
String ans = "NG";
for (int i = A; i <= B; i++) {
if (i % K == 0) {
... | [["-", 0, 195, 8, 196, 0, 7, 15, 16, 17, 20], ["+", 0, 195, 8, 196, 0, 7, 15, 16, 17, 19]] | 3 | 115 |
#include <bits/stdc++.h>
using namespace std;
int main() {
int k, a, b;
int j = 0;
cin >> k;
cin >> a >> b;
for (int i = a; i < b; i++) {
if (i % k == 0)
j++;
}
if (k == 1)
cout << "OK" << endl;
else if (j > 0)
cout << "OK" << endl;
else
cout << "NG" << endl;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
int k, a, b;
int j = 0;
cin >> k;
cin >> a >> b;
for (int i = a; i <= b; i++) {
if (i % k == 0)
j++;
}
if (k == 1)
cout << "OK" << endl;
else if (j > 0)
cout << "OK" << endl;
else
cout << "NG" << endl;
} | [["-", 0, 14, 8, 9, 0, 7, 15, 16, 17, 18], ["+", 0, 14, 8, 9, 0, 7, 15, 16, 17, 19]] | 1 | 99 |
#include <bits/stdc++.h>
#include <stdio.h>
#include <stdlib.h>
using namespace std;
int main() {
int k;
int a, b;
cin >> k >> a >> b;
int ak = a / k;
int bk = b / k + 1;
int num = ak * k;
while (ak <= bk) {
num = ak * k;
if (a <= num && num <= b) {
cout << "OK" << endl;
return 0;
... | #include <bits/stdc++.h>
#include <stdio.h>
#include <stdlib.h>
using namespace std;
int main() {
int k;
int a, b;
cin >> k >> a >> b;
int ak = a / k;
int bk = b / k + 1;
int num = ak * k;
while (ak <= bk) {
num = ak * k;
if (a <= num && num <= b) {
cout << "OK" << endl;
return 0;
... | [["-", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["+", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6]] | 1 | 107 |
a = int(input())
b,c = map(int,input().split())
for i in range(b,c):
if i%a == 0:
print("OK")
break
else:
print("NG") | a = int(input())
b,c = map(int,input().split())
for i in range(b,c+1):
if i%a == 0:
print("OK")
quit()
else:
print("NG")
| [["+", 0, 7, 12, 652, 3, 4, 0, 657, 17, 72], ["+", 0, 7, 12, 652, 3, 4, 0, 657, 12, 612], ["-", 8, 196, 0, 57, 64, 196, 0, 93, 0, 94], ["+", 0, 57, 64, 196, 0, 1, 0, 652, 63, 22], ["+", 64, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["+", 64, 196, 0, 1, 0, 652, 3, 4, 0, 25]] | 5 | 56 |
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
constexpr ll MOD = 1e9 + 7;
constexpr ll INF = 1e18;
int main() {
ll n, m, i, j, k;
cin >> k;
cin >> n >> m;
for (i = n; i < m; i++) {
if (i % k == 0) {
cout << "OK" << endl;
return 0;
}
}
cout << "NG" << endl;
retu... | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
constexpr ll MOD = 1e9 + 7;
constexpr ll INF = 1e18;
int main() {
ll n, m, i, j, k;
cin >> k;
cin >> n >> m;
for (i = n; i <= m; i++) {
if (i % k == 0) {
cout << "OK" << endl;
return 0;
}
}
cout << "NG" << endl;
ret... | [["-", 0, 14, 8, 9, 0, 7, 15, 16, 17, 18], ["+", 0, 14, 8, 9, 0, 7, 15, 16, 17, 19]] | 1 | 100 |
#include <iostream>
using namespace std;
int main() {
int K, A, B;
bool flag;
cin >> K >> A >> B;
flag = false;
for (int i = 1; i <= 1000; i++) {
if (A <= i * K <= B) {
flag = true;
break;
}
}
if (flag) {
cout << "OK" << endl;
} else {
cout << "NG" << endl;
}
return 0;... | #include <iostream>
using namespace std;
int main() {
int K, A, B;
bool flag;
cin >> K >> A >> B;
flag = false;
for (int i = 1; i <= 1000; i++) {
if (A <= i * K and i * K <= B) {
flag = true;
break;
}
}
if (flag) {
cout << "OK" << endl;
} else {
cout << "NG" << endl;
}
... | [["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 355], ["+", 15, 339, 51, 16, 12, 16, 31, 16, 31, 22], ["+", 15, 339, 51, 16, 12, 16, 31, 16, 17, 48], ["+", 15, 339, 51, 16, 12, 16, 31, 16, 12, 22]] | 1 | 96 |
k=int(input())
a,b=map(int,input().split())
if b-a>=k-1 or b%k<=a%k or a%k==0:
print('OK')
else:
print('NG') | k=int(input())
a,b=map(int,input().split())
if b-a>=k-1 or b%k<a%k or a%k==0:
print('OK')
else:
print('NG') | [["-", 0, 57, 15, 679, 31, 679, 12, 666, 667, 19], ["+", 0, 57, 15, 679, 31, 679, 12, 666, 667, 18]] | 5 | 61 |
function Main(input) {
input = input.split("\n");
var number = input[1].split(" ");
var k = parseInt(input[0], 10);
var a = parseInt(number[0], 10);
var b = parseInt(number[1], 10);
if (a % k === 0 || (b - a) > (k - a % k)) {
console.log("OK");
} else {
console.log("NG");
}
}
Main(require("fs"... | function Main(input) {
input = input.split("\n");
var number = input[1].split(" ");
var k = parseInt(input[0], 10);
var a = parseInt(number[0], 10);
var b = parseInt(number[1], 10);
if (a % k === 0 || (b - a) >= (k - a % k)) {
console.log("OK");
} else {
console.log("NG");
}
}
Main(require("fs... | [["-", 0, 57, 15, 23, 0, 16, 12, 16, 17, 47], ["+", 0, 57, 15, 23, 0, 16, 12, 16, 17, 20]] | 2 | 138 |
#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (n); i++)
#define all(x) (x).begin(), (x).end()
#define bit(x) (1L << (x))
using ll = long long;
using namespace std;
template <typename T> vector<T> make_v(size_t a, T b) {
return vector<T>(a, b);
}
template <typename... Ts> auto make_v(size_t a, Ts...... | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (n); i++)
#define all(x) (x).begin(), (x).end()
#define bit(x) (1L << (x))
using ll = long long;
using namespace std;
template <typename T> vector<T> make_v(size_t a, T b) {
return vector<T>(a, b);
}
template <typename... Ts> auto make_v(size_t a, Ts...... | [["-", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["+", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6]] | 1 | 171 |
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") | [["-", 0, 57, 64, 196, 0, 1, 0, 662, 0, 32], ["+", 0, 57, 64, 196, 0, 1, 0, 677, 17, 107], ["+", 8, 196, 0, 57, 64, 196, 0, 93, 0, 94]] | 5 | 72 |
#include <algorithm>
#include <assert.h>
#include <bitset>
#include <complex>
#include <cstdint>
#include <deque>
#include <functional>
#include <iomanip>
#include <iostream>
#include <map>
#include <math.h>
#include <numeric>
#include <queue>
#include <set>
#include <stack>
#include <stdio.h>
#include <stdlib.h>
#incl... | #include <algorithm>
#include <assert.h>
#include <bitset>
#include <complex>
#include <cstdint>
#include <deque>
#include <functional>
#include <iomanip>
#include <iostream>
#include <map>
#include <math.h>
#include <numeric>
#include <queue>
#include <set>
#include <stack>
#include <stdio.h>
#include <stdlib.h>
#incl... | [["-", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 22]] | 1 | 402 |
K= int(input())
A, B = map(int, input().split())
sum=0
for i in range(A+1,B+1,1):
if i%K==0:
sum+=1
if sum>=1:
print('OK')
else:
print('NG') | K= int(input())
A, B = map(int, input().split())
sum=0
for i in range(A,B+1,1):
if i%K==0:
sum+=1
if sum>=1:
print('OK')
else:
print('NG') | [["-", 0, 7, 12, 652, 3, 4, 0, 657, 17, 72], ["-", 0, 7, 12, 652, 3, 4, 0, 657, 12, 612]] | 5 | 72 |
K = int(input())
A, B = map(int, input().split())
for num in range(1,1000):
if A <= K*num <= B:
print('OK')
break
print('NG') | K = int(input())
A, B = map(int, input().split())
for num in range(1,1000):
if A <= K*num <= B:
print('OK')
break
else:
print('NG')
| [["+", 36, 36, 0, 656, 0, 7, 75, 76, 0, 95], ["+", 36, 36, 0, 656, 0, 7, 75, 76, 0, 102]] | 5 | 56 |
#include <math.h>
#include <algorithm>
#include <cstring>
#include <iostream>
#include <string>
#include <vector>
using namespace std;
#define rep(i, n) for (int i = 0; i < n; i++)
using ll = long long;
int main() {
int k, a, b;
cin >> k >> a >> b;
for (int i = a; a <= b; i++) {
if (i % k == 0) {
cou... | #include <math.h>
#include <algorithm>
#include <cstring>
#include <iostream>
#include <string>
#include <vector>
using namespace std;
#define rep(i, n) for (int i = 0; i < n; i++)
using ll = long long;
int main() {
int k, a, b;
cin >> k >> a >> b;
for (int i = a; i <= b; i++) {
if (i % k == 0) {
cou... | [["-", 0, 14, 8, 9, 0, 7, 15, 16, 31, 22], ["+", 0, 14, 8, 9, 0, 7, 15, 16, 31, 22]] | 1 | 97 |
k = int(input())
a,b = list(map(int,input().slplit()))
ret = ""
q = a//k
if a <= q*k or (q+1)*k <= b:
ret = "OK"
else:
ret ="NG"
print(ret) | k = int(input())
a,b = list(map(int,input().split()))
ret = ""
q = a//k
if a <= q*k or (q+1)*k <= b:
ret = "OK"
else:
ret ="NG"
print(ret) | [["-", 0, 652, 3, 4, 0, 652, 63, 319, 319, 22], ["+", 0, 652, 3, 4, 0, 652, 63, 319, 319, 22]] | 5 | 69 |
#include <algorithm>
#include <bitset>
#include <complex>
#include <deque>
#include <exception>
#include <fstream>
#include <functional>
#include <iomanip>
#include <ios>
#include <iosfwd>
#include <iostream>
#include <istream>
#include <iterator>
#include <limits>
#include <list>
#include <locale>
#include <map>
#incl... | #include <algorithm>
#include <bitset>
#include <complex>
#include <deque>
#include <exception>
#include <fstream>
#include <functional>
#include <iomanip>
#include <ios>
#include <iosfwd>
#include <iostream>
#include <istream>
#include <iterator>
#include <limits>
#include <list>
#include <locale>
#include <map>
#incl... | [["+", 8, 9, 0, 57, 64, 9, 0, 93, 0, 94], ["+", 8, 9, 0, 57, 64, 9, 0, 93, 0, 35]] | 1 | 159 |
import sys
def main():
k = int(input())
a,b = map(int, input().split())
n = "OK"
for ai in range(a,b+1):
if ai%k==0:
break
sys.exit()
else:
n="NG"
print(n)
if __name__ == "__main__":
main()
| import sys
def main():
k = int(input())
a,b = map(int, input().split())
n = "OK"
for ai in range(a,b+1):
if ai%k==0:
n = "OK"
break
sys.exit()
else:
n="NG"
print(n)
if __name__ == "__main__":
main() | [["+", 0, 57, 64, 196, 0, 1, 0, 662, 31, 22], ["+", 0, 57, 64, 196, 0, 1, 0, 662, 0, 32], ["+", 64, 196, 0, 1, 0, 662, 12, 557, 0, 654], ["+", 64, 196, 0, 1, 0, 662, 12, 557, 0, 6], ["+", 64, 196, 0, 1, 0, 662, 12, 557, 0, 655]] | 5 | 82 |
A = int(input())
B,C = map(int,input().split())
f = "No"
for i in range(B,C+1):
if i % A == 0:
f = "Yes"
print(f) | A = int(input())
B,C = map(int,input().split())
f = "NG"
for i in range(B,C+1):
if i % A == 0:
f = "OK"
print(f) | [["-", 0, 656, 0, 1, 0, 662, 12, 557, 0, 6], ["+", 0, 656, 0, 1, 0, 662, 12, 557, 0, 6], ["-", 64, 196, 0, 1, 0, 662, 12, 557, 0, 6], ["+", 64, 196, 0, 1, 0, 662, 12, 557, 0, 6]] | 5 | 57 |
#include <iostream>
using namespace std;
int main() {
int k, a, b;
cin >> k >> a >> b;
for (int i = 1; i * k <= b; i++) {
if (a <= i * k && i * k <= b) {
cout << "OK" << endl;
return 0;
}
}
cout << "NO" << endl;
return 0;
}
| #include <iostream>
using namespace std;
int main() {
int k, a, b;
cin >> k >> a >> b;
for (int i = 1; i * k <= b; i++) {
if (a <= i * k && i * k <= b) {
cout << "OK" << endl;
return 0;
}
}
cout << "NG" << endl;
return 0;
}
| [["-", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["+", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6]] | 1 | 83 |
#include <iostream>
using namespace std;
int main(void) {
int a, b, k, f;
cin >> k >> a >> b;
f = 0;
for (int i = a; (a + i) <= b; ++i) {
if ((a + i) % k == 0) {
cout << "OK" << endl;
f = 1;
break;
}
}
if (f == 0) {
cout << "NG" << endl;
}
} | #include <iostream>
using namespace std;
int main(void) {
int a, b, k, f;
cin >> k >> a >> b;
f = 0;
for (int i = 0; (a + i) <= b; ++i) {
if ((a + i) % k == 0) {
cout << "OK" << endl;
f = 1;
break;
}
}
if (f == 0) {
cout << "NG" << endl;
}
} | [["-", 8, 9, 0, 7, 10, 43, 49, 50, 51, 22], ["+", 8, 9, 0, 7, 10, 43, 49, 50, 51, 13]] | 1 | 98 |
K=int(input())
A,B =input().split()
if (((int(A)//K)+1) <= (int(B)//K)):
print("OK")
elif(K==1):
print("OK")
elif(int(A)//K==0):
print("OK")
else:
print("NG")
| K=int(input())
A,B =input().split()
if (((int(A)//K)+1) <= (int(B)//K)):
print("OK")
elif(K==1):
print("OK")
elif(int(A)%K==0):
print("OK")
else:
print("NG")
| [["-", 75, 665, 15, 23, 0, 666, 0, 657, 17, 676], ["+", 75, 665, 15, 23, 0, 666, 0, 657, 17, 109]] | 5 | 89 |
#include <bits/stdc++.h>
using namespace std;
int main() {
int A, B, C, K;
bool flag = false;
cin >> K >> A >> B;
if (A % K == 0)
flag = true;
C = A % K;
C++;
C = C * K;
if (C <= B)
flag = true;
if (flag)
cout << "OK" << endl;
else
cout << "NG" << endl;
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
int A, B, C, K;
bool flag = false;
cin >> K >> A >> B;
if (A % K == 0)
flag = true;
C = A / K;
C++;
C = C * K;
if (C <= B)
flag = true;
if (flag)
cout << "OK" << endl;
else
cout << "NG" << endl;
}
| [["-", 8, 9, 0, 1, 0, 11, 12, 16, 17, 109], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 17, 85]] | 1 | 92 |
#include <algorithm>
#include <bitset>
#include <cmath>
#include <cstring>
#include <deque>
#include <iomanip>
#include <iostream>
#include <list>
#include <map>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <unordered_set>
#include <vector>
using namespace std;
// int x=atoi(s.c_str()); ... | #include <algorithm>
#include <bitset>
#include <cmath>
#include <cstring>
#include <deque>
#include <iomanip>
#include <iostream>
#include <list>
#include <map>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <unordered_set>
#include <vector>
using namespace std;
// int x=atoi(s.c_str()); ... | [["-", 0, 57, 15, 339, 51, 16, 31, 16, 31, 22], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 31, 22], ["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 79], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 60], ["-", 64, 9, 0, 1, 0, 16, 12, 5, 0, 6], ["+", 64, 9, 0, 1, 0, 16, 12, 5, 0, 6], ["-", 8, 9, 0, 1, 0, 16, 12, 5, 0, 6], ["+", 8, 9, 0, 1... | 1 | 404 |
k = int(input())
a,b = list(map(int,input().split()))
flag=False
for i in range(a,b+1):
if i % k == 0:
flag =True
if(flag):
print('OK')
else:
print('NO') | k = int(input())
a,b = list(map(int,input().split()))
flag=False
for i in range(a,b+1):
if i % k == 0:
flag =True
if(flag):
print('OK')
else:
print('NG')
| [["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6]] | 5 | 71 |
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())
A, B = map(int, input().split())
word = "NG"
for i in range(A, B+1):
if i % K == 0:
word = "OK"
print(word)
| [["-", 3, 4, 0, 652, 3, 4, 0, 557, 0, 654], ["-", 3, 4, 0, 652, 3, 4, 0, 557, 0, 6], ["-", 3, 4, 0, 652, 3, 4, 0, 557, 0, 655]] | 5 | 60 |
#include <bits/stdc++.h>
using namespace std;
int main() {
int k, a, b;
cin >> k;
cin >> a >> b;
if (a % k == 0) {
cout << "OK" << endl;
return 0;
}
int digit;
digit = (a / k + 1) * k;
if (digit > a && digit < b)
cout << "OK" << endl;
else
cout << "NG" << endl;
return 0;
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
int k, a, b;
cin >> k;
cin >> a >> b;
if (a % k == 0) {
cout << "OK" << endl;
return 0;
}
int digit;
digit = (a / k + 1) * k;
if (digit > a && digit <= b)
cout << "OK" << endl;
else
cout << "NG" << endl;
return 0;
}
| [["-", 0, 57, 15, 339, 51, 16, 12, 16, 17, 18], ["+", 0, 57, 15, 339, 51, 16, 12, 16, 17, 19]] | 1 | 95 |
#include <bits/stdc++.h>
using namespace std;
int main() {
int k, a, b;
cin >> k >> a >> b;
if (b - a + 1 >= k)
cout << "OK";
else if ((a / k + 1) * k < b)
cout << "OK";
else if (a / k * k == a)
cout << "OK";
else
cout << "NG";
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
int k, a, b;
cin >> k >> a >> b;
if (b - a + 1 >= k)
cout << "OK";
else if ((a / k + 1) * k <= b)
cout << "OK";
else if (a / k * k == a)
cout << "OK";
else
cout << "NG";
}
| [["-", 75, 76, 0, 57, 15, 339, 51, 16, 17, 18], ["+", 75, 76, 0, 57, 15, 339, 51, 16, 17, 19]] | 1 | 88 |
#include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
typedef int64_t ll;
int main() {
int k, a, b;
cin >> k >> a >> b;
bool flag = false;
for (int x = a; x <= b; x++) {
if (x % k == 0)
flag = true;
}
if (flag)
printf("OK");
else
printf("NO")... | #include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
typedef int64_t ll;
int main() {
int k, a, b;
cin >> k >> a >> b;
bool flag = false;
for (int x = a; x <= b; x++) {
if (x % k == 0)
flag = true;
}
if (flag)
printf("OK");
else
printf("NG")... | [["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6]] | 1 | 91 |
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")
break
else:
print("NG") | [["+", 8, 196, 0, 57, 15, 666, 0, 23, 0, 24], ["+", 8, 196, 0, 57, 15, 666, 0, 23, 0, 25], ["+", 8, 196, 0, 57, 64, 196, 0, 93, 0, 94]] | 5 | 57 |
#include <bits/stdc++.h>
using namespace std;
int main() {
int K, A, B;
cin >> K;
cin >> A >> B;
while (A < B) {
if (A % K == 0) {
cout << "OK" << endl;
return 0;
} else {
A++;
}
}
cout << "NG" << endl;
return 0;
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
int K, A, B;
cin >> K;
cin >> A >> B;
while (A <= B) {
if (A % K == 0) {
cout << "OK" << endl;
return 0;
} else {
A++;
}
}
cout << "NG" << endl;
return 0;
}
| [["-", 8, 9, 0, 52, 15, 339, 51, 16, 17, 18], ["+", 8, 9, 0, 52, 15, 339, 51, 16, 17, 19]] | 1 | 75 |
N = int(input())
A=input().split()
s=int(A[0])//N
if int(A[0])%N==0:
print('OK')
else:
if (s+1)*N>=A[1]:
print('NG')
else:
print('OK')
| 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')
| [["-", 75, 76, 8, 196, 0, 57, 15, 666, 667, 20], ["+", 75, 76, 8, 196, 0, 57, 15, 666, 667, 47], ["+", 8, 196, 0, 57, 15, 666, 0, 652, 63, 22], ["+", 0, 57, 15, 666, 0, 652, 3, 4, 0, 24], ["+", 0, 57, 15, 666, 0, 652, 3, 4, 0, 25]] | 5 | 77 |
## A
K = int(input())
A, B = map(int, input().split())
rt = 'NG'
if A == B:
if A%K == 0:
rt = 'OK'
else:
for i in range(A+1,B+1):
if i%K == 0:
rt = 'OK'
break
print(rt) | ## A
K = int(input())
A, B = map(int, input().split())
rt = 'NG'
if A == B:
if A%K == 0:
rt = 'OK'
else:
for i in range(A,B+1):
if i%K == 0:
rt = 'OK'
break
print(rt) | [["-", 0, 7, 12, 652, 3, 4, 0, 657, 17, 72], ["-", 0, 7, 12, 652, 3, 4, 0, 657, 12, 612]] | 5 | 80 |
function main(input) {
const parsedInput = parser(input);
if (isAchievement(parsedInput.a, parsedInput.b, parsedInput.k)) {
console.log('Ok');
return;
}
console.log('Ng');
}
function parser(inputStr) {
const splitInput = inputStr.split('\n');
const splitInputAandB = splitInput[1].split(' ');
retur... | function main(input) {
const parsedInput = parser(input);
if (isAchievement(parsedInput.a, parsedInput.b, parsedInput.k)) {
console.log('OK');
return;
}
console.log('NG');
}
function parser(inputStr) {
const splitInput = inputStr.split('\n');
const splitInputAandB = splitInput[1].split(' ');
retur... | [["-", 0, 1, 0, 2, 3, 3, 0, 557, 0, 491], ["+", 0, 1, 0, 2, 3, 3, 0, 557, 0, 491]] | 2 | 204 |
#include <bits/stdc++.h>
using namespace std;
void Main() {}
int main() {
int a, b, c, d = 0;
cin >> a;
cin >> b >> c;
for (; d < c;) {
d += a;
if (d > b && d < c) {
cout << "OK" << endl;
break;
} else if (c < d) {
cout << "NG" << endl;
break;
}
}
Main();
} | #include <bits/stdc++.h>
using namespace std;
void Main() {}
int main() {
int a, b, c, d = 0;
cin >> a;
cin >> b >> c;
for (; d <= c;) {
d += a;
if (d >= b && d <= c) {
cout << "OK" << endl;
break;
} else if (c < d) {
cout << "NG" << endl;
break;
}
}
Main();
} | [["-", 0, 14, 8, 9, 0, 7, 15, 16, 17, 18], ["+", 0, 14, 8, 9, 0, 7, 15, 16, 17, 19], ["-", 0, 57, 15, 339, 51, 16, 31, 16, 17, 47], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 20], ["-", 0, 57, 15, 339, 51, 16, 12, 16, 17, 18], ["+", 0, 57, 15, 339, 51, 16, 12, 16, 17, 19]] | 1 | 98 |
#include <bits/stdc++.h>
#define M_PI 3.14159265358979323846 // pi
using namespace std;
typedef long long ll;
typedef unsigned long long ull;
typedef vector<ll> VI;
typedef pair<ll, ll> P;
typedef tuple<ll, ll, ll> t3;
typedef tuple<ll, ll, ll, ll> t4;
#define rep(a, n) for (ll a = 0; a < n; a++)
#define repi(a, b, ... | #include <bits/stdc++.h>
#define M_PI 3.14159265358979323846 // pi
using namespace std;
typedef long long ll;
typedef unsigned long long ull;
typedef vector<ll> VI;
typedef pair<ll, ll> P;
typedef tuple<ll, ll, ll> t3;
typedef tuple<ll, ll, ll, ll> t4;
#define rep(a, n) for (ll a = 0; a < n; a++)
#define repi(a, b, ... | [["-", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["+", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6]] | 1 | 167 |
#include <bits/stdc++.h>
using namespace std;
int n, a, b;
int main() {
cin >> n >> a >> b;
for (int i = a; i <= b; i++)
if (i % n == 0) {
cout << "Ok";
break;
}
cout << "NG";
return 0;
} | #include <bits/stdc++.h>
using namespace std;
int n, a, b;
int main() {
cin >> n >> a >> b;
for (int i = a; i <= b; i++)
if (i % n == 0) {
cout << "OK";
return 0;
}
cout << "NG";
return 0;
} | [["-", 64, 9, 0, 1, 0, 16, 12, 5, 0, 6], ["+", 64, 9, 0, 1, 0, 16, 12, 5, 0, 6], ["-", 0, 7, 8, 57, 64, 9, 0, 93, 0, 94], ["+", 0, 7, 8, 57, 64, 9, 0, 37, 0, 38], ["+", 0, 7, 8, 57, 64, 9, 0, 37, 0, 13]] | 1 | 68 |
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <functional>
#include <iostream>
#define mp make_pair
#define mt make_tuple
#define fi first
#define se second
#define pb push_back
#define all(x) (x).begin(), (x).end()
#define rall(x) (x).rbegin(), (x).rend... | #include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <functional>
#include <iostream>
#define mp make_pair
#define mt make_tuple
#define fi first
#define se second
#define pb push_back
#define all(x) (x).begin(), (x).end()
#define rall(x) (x).rbegin(), (x).rend... | [["+", 0, 1, 0, 16, 31, 16, 31, 16, 12, 22], ["+", 8, 9, 0, 1, 0, 16, 31, 16, 17, 152], ["-", 0, 14, 8, 9, 0, 1, 0, 16, 17, 152], ["-", 0, 14, 8, 9, 0, 1, 0, 16, 12, 22]] | 1 | 382 |
k = int(input())
a, b = map(int,input().split())
if a%k == 0:
res_k = a*k
else:
res_k = (a//k + 1)*k
if res_k >= a and res_k <= b:
print('OK')
else:
print('NG') | k = int(input())
a, b = map(int,input().split())
if a%k == 0:
res_k = a
else:
res_k = (a//k + 1)*k
if (res_k >= a) and (res_k <= b):
print('OK')
else:
print('NG') | [["-", 64, 196, 0, 1, 0, 662, 12, 657, 17, 48], ["-", 64, 196, 0, 1, 0, 662, 12, 657, 12, 22], ["+", 0, 656, 0, 57, 15, 679, 31, 23, 0, 24], ["+", 0, 656, 0, 57, 15, 679, 31, 23, 0, 25], ["+", 0, 656, 0, 57, 15, 679, 12, 23, 0, 24], ["+", 0, 656, 0, 57, 15, 679, 12, 23, 0, 25]] | 5 | 72 |
k = int(input())
a,b = map(int,input().split())
if a//k == a//k:
if a%k == 0:
print("OK")
else:
print("NG")
else:
print("OK") | k = int(input())
a,b = map(int,input().split())
if a//k == b//k:
if a%k == 0:
print("OK")
else:
print("NG")
else:
print("OK") | [["-", 0, 656, 0, 57, 15, 666, 0, 657, 31, 22], ["+", 0, 656, 0, 57, 15, 666, 0, 657, 31, 22]] | 5 | 62 |
#include <iostream>
using namespace std;
int main() {
int k;
int a, b;
cin >> k;
cin >> a >> b;
int i = 1;
while ((i * k) < a) {
i++;
}
if ((i * k) < b)
printf("OK");
else
printf("NG");
}
| #include <iostream>
using namespace std;
int main() {
int k;
int a, b;
cin >> k;
cin >> a >> b;
int i = 1;
while ((i * k) < a) {
i++;
}
if ((i * k) <= b)
printf("OK");
else
printf("NG");
}
| [["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 18], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 19]] | 1 | 75 |
k = int(input())
a, b = map(int, input().split())
if k<a:
if a%k == 0:
print("OK")
elif b%k == 0:
print("OK")
elif(a+(k-a%k)) <= b:
print("OK")
else:
print("NG")
elif k<b:
print("OK")
else:
print("NG") | k = int(input())
a, b = map(int, input().split())
if k<a:
if a%k == 0:
print("OK")
elif b%k == 0:
print("OK")
elif(a+(k-a%k)) <= b:
print("OK")
else:
print("NG")
elif k<=b:
print("OK")
else:
print("NG")
| [["-", 0, 656, 0, 57, 75, 665, 15, 666, 667, 18], ["+", 0, 656, 0, 57, 75, 665, 15, 666, 667, 19]] | 5 | 103 |
#include <stdio.h>
int main() {
int a, b, k, i, p = 0;
scanf("%d %d %d", &k, &a, &b);
for (i = a; i <= b; i++) {
if (i % k == 0) {
printf("Ok\n");
p++;
break;
}
}
if (p == 0) {
printf("Ng\n");
}
return 0;
}
| #include <stdio.h>
int main() {
int a, b, k, i, p = 0;
scanf("%d %d %d", &k, &a, &b);
for (i = a; i <= b; i++) {
if (i % k == 0) {
printf("OK\n");
p++;
break;
}
}
if (p == 0) {
printf("NG\n");
}
return 0;
}
| [["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6]] | 0 | 94 |
#include <iostream>
using namespace std;
int main() {
int k, a, b;
cin >> k;
cin >> a >> b;
if (k >= a && k <= b) {
cout << "OK";
return 0;
} else {
int i = 2;
while (k * i < b) {
if (k * i >= a && k * i <= b) {
cout << "OK";
return 0;
}
i++;
}
}
cou... | #include <iostream>
using namespace std;
int main() {
int k, a, b;
cin >> k;
cin >> a >> b;
if (k >= a && k <= b) {
cout << "OK";
return 0;
} else {
int i = 2;
while (k * i <= b) {
if (k * i >= a && k * i <= b) {
cout << "OK";
return 0;
}
i++;
}
}
co... | [["-", 0, 9, 0, 52, 15, 339, 51, 16, 17, 18], ["+", 0, 9, 0, 52, 15, 339, 51, 16, 17, 19]] | 1 | 105 |
#include <stdio.h>
#include <stdlib.h>
int main() {
int ret;
int K, A, B, i;
int hit = 0;
ret = scanf("%d", &K);
ret = scanf(" %d %d", &A, &B);
for (i = A; i <= B; i++) {
if (i % K == 0)
hit = 1;
}
if (hit)
printf("YES");
else
printf("NO");
fflush(stdout);
return EXIT_SUCCESS;... | #include <stdio.h>
#include <stdlib.h>
int main() {
int ret;
int K, A, B, i;
int hit = 0;
ret = scanf("%d", &K);
ret = scanf("%d %d", &A, &B);
for (i = A; i <= B; i++) {
if (i % K == 0)
hit = 1;
}
if (hit)
printf("OK");
else
printf("NG");
fflush(stdout);
return EXIT_SUCCESS;
}... | [["-", 0, 11, 12, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 11, 12, 2, 3, 4, 0, 5, 0, 6], ["-", 64, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 64, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6]] | 0 | 108 |
#include <bits/stdc++.h>
using namespace std;
int main() {
int N, M, O, cnt = 0;
cin >> N >> M >> O;
for (int i = M; i <= O; i++) {
if (i % N == 0) {
cout << "OK" << endl;
cnt = 1;
break;
}
}
if (cnt == 0)
cout << "NO" << endl;
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
int N, M, O, cnt = 0;
cin >> N >> M >> O;
for (int i = M; i <= O; i++) {
if (i % N == 0) {
cout << "OK" << endl;
cnt = 1;
break;
}
}
if (cnt == 0)
cout << "NG" << endl;
}
| [["-", 64, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["+", 64, 1, 0, 16, 31, 16, 12, 5, 0, 6]] | 1 | 85 |
#include <bits/stdc++.h>
using namespace std;
int main() {
int k, a, b;
cin >> k >> a >> b;
for (int i = 1;; i++) {
if (k * i > b) {
break;
}
if (a <= k * i && k * i <= b) {
cout << "OK" << endl;
return 0;
}
}
cout << "NO" << endl;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
int k, a, b;
cin >> k >> a >> b;
for (int i = 1;; i++) {
if (k * i > b) {
break;
}
if (a <= k * i && k * i <= b) {
cout << "OK" << endl;
return 0;
}
}
cout << "NG" << endl;
} | [["-", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["+", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6]] | 1 | 87 |
K = int(input())
A, B = map(int, input().split())
N = A // K
if K*(N+1) <= B:
print("OK")
elif K == A*N:
print("OK")
else:
print("NG") | K = int(input())
A, B = map(int, input().split())
N = A // K
if K*(N+1) <= B:
print("OK")
elif A == K*N:
print("OK")
else:
print("NG") | [["-", 0, 656, 0, 57, 75, 665, 15, 666, 0, 22], ["-", 0, 656, 0, 57, 75, 665, 15, 666, 667, 60], ["+", 0, 656, 0, 57, 75, 665, 15, 666, 667, 60], ["+", 0, 57, 75, 665, 15, 666, 0, 657, 31, 22]] | 5 | 67 |
#include <bits/stdc++.h>
using namespace std;
int main() {
int K;
cin >> K;
int A, B;
cin >> A >> B;
string messages = "NG";
int i = A / K;
while (i <= B) {
if (i < A) {
i += K;
continue;
}
messages = "OK";
i += K;
}
cout << messages << endl;
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
int K;
cin >> K;
int A, B;
cin >> A >> B;
string messages = "NG";
int i = A / K;
i = i * K;
while (i <= B) {
if (i < A) {
i += K;
continue;
}
messages = "OK";
i += K;
}
cout << messages << endl;
}
| [["+", 0, 14, 8, 9, 0, 1, 0, 11, 31, 22], ["+", 0, 14, 8, 9, 0, 1, 0, 11, 17, 32], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 31, 22], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 17, 48], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 12, 22], ["+", 0, 30, 0, 14, 8, 9, 0, 1, 0, 35]] | 1 | 82 |
import java.io.*;
public class Main {
public static void main(String[] args) throws IOException {
int K;
String str;
String[] A = new String[2];
String ans = "No";
BufferedReader r = new BufferedReader(new InputStreamReader(System.in));
K = Integer.parseInt(r.readLine());
str = r.readLine(... | import java.io.*;
public class Main {
public static void main(String[] args) throws IOException {
int K;
String str;
String[] A = new String[2];
String ans = "NG";
BufferedReader r = new BufferedReader(new InputStreamReader(System.in));
K = Integer.parseInt(r.readLine());
str = r.readLine(... | [["-", 8, 196, 0, 503, 49, 200, 51, 5, 0, 491], ["+", 8, 196, 0, 503, 49, 200, 51, 5, 0, 491], ["-", 64, 196, 0, 1, 0, 11, 12, 5, 0, 491], ["+", 64, 196, 0, 1, 0, 11, 12, 5, 0, 491]] | 3 | 174 |
import sys
input = sys.stdin.readline
k = int(input())
a, b = map(int, input().replace("\n","").split())
if a == b:
if a % k == 0:
print("OK")
exit()
for i in range(a,b):
if i % k == 0:
print("OK")
exit()
print("NG") | import sys
input = sys.stdin.readline
k = int(input())
a, b = map(int, input().replace("\n","").split())
if a == b:
if a % k == 0:
print("OK")
exit()
for i in range(a,b+1):
if i % k == 0:
print("OK")
exit()
print("NG") | [["+", 0, 7, 12, 652, 3, 4, 0, 657, 17, 72], ["+", 0, 7, 12, 652, 3, 4, 0, 657, 12, 612]] | 5 | 96 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.