criyle/codenet-compile-errors huggingface dataset:
Language: C++

#include<stdio.h>

int main(){
	 
	int a, b, k, condition;
	
	scanf("%d", &k);
	scanf("%d %d", &a, &b);
	
	}
	
	while(a!=b){
		a++;
		if(a%k==0){
			printf("OK");
			break;
		}
		else{
			condition=a;
			continue;
		}
	}
	if (condition==a)
{
	printf("NG");
	}	
	
	return 0;
}

Compiler output:
a.cc:12:9: error: expected unqualified-id before 'while'
   12 |         while(a!=b){
      |         ^~~~~
a.cc:23:9: error: expected unqualified-id before 'if'
   23 |         if (condition==a)
      |         ^~
a.cc:28:9: error: expected unqualified-id before 'return'
   28 |         return 0;
      |         ^~~~~~
a.cc:29:1: error: expected declaration before '}' token
   29 | }
      | ^
Language: C++

#include <stdio.h>

int main(){
int a,b,c;
scanf ("%d", &a);
scanf ("%d %d",&b,&c);
for(int i=a;a<=b;i++){
	if (c%a==0){
		printf("OK\n");
		break;
	}else {
		printf("NG");
		break;
	}

Compiler output:
a.cc: In function 'int main()':
a.cc:14:10: error: expected '}' at end of input
   14 |         }
      |          ^
a.cc:7:22: note: to match this '{'
    7 | for(int i=a;a<=b;i++){
      |                      ^
a.cc:14:10: error: expected '}' at end of input
   14 |         }
      |          ^
a.cc:3:11: note: to match this '{'
    3 | int main(){
      |           ^
Language: C

include <stdio.h>

int main()
{
    int n, a, b;
    int flag = 0;
    
    scanf("%d", &n);

    scanf("%d %d", &a, &b);
    
    for(int i = a ; i <= b; i++){
        if(i % n == 0){
            flag = 1;
        }
    }
    if(flag == 1){
        printf("OK\n");
    }else{
        printf("NG\n");
    }
}

Compiler output:
main.c:1:9: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
    1 | include <stdio.h>
      |         ^
Language: C

include<stdio.h>

int main()
{
    int n, a, b;
    int flag = 0;
    
    scanf("%d", &n);

    scanf("%d %d", &a, &b);
    
    for(int i = a ; i <= b; i++){
        if(i % n == 0){
            flag = 1;
        }
    }
    if(flag == 1){
        printf("OK\n");
    }else{
        printf("NG\n");
    }
}

Compiler output:
main.c:1:8: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
    1 | include<stdio.h>
      |        ^
Language: C++

int main(){
	int A, B, C;
	scanf("%d \n%d %d", &A, &B, &C);
	for (int i = B; i <= C; i++){
		if (i%A == 0){
		printf("OK");
		return 0;}
	}
	printf("NG");
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:3:9: error: 'scanf' was not declared in this scope
    3 |         scanf("%d \n%d %d", &A, &B, &C);
      |         ^~~~~
a.cc:6:17: error: 'printf' was not declared in this scope
    6 |                 printf("OK");
      |                 ^~~~~~
a.cc:1:1: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
  +++ |+#include <cstdio>
    1 | int main(){
a.cc:9:9: error: 'printf' was not declared in this scope
    9 |         printf("NG");
      |         ^~~~~~
a.cc:9:9: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
Language: C++

#include <stdio.h>
int main()
{
	int k,a,b;
	int flag = 0;
	
	scanf("%d",&k);
	scanf("%d %d",&a,&b);
	
	for ( i = a; i <= b; i++)
	{
		if ( i % k == 0)
		{
			flag = 1;
		}
	}
	
	if (flag == 1)
	{
		printf("OK\n");
	} else {
		printf("NG\n");
	}
	
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:15: error: 'i' was not declared in this scope
   10 |         for ( i = a; i <= b; i++)
      |               ^
Language: C++

#include <stdio.h>
 
int main(){
	int A, B, C;
	scanf("%d \n%d %d", &A, &B, &C);
	for (int i = B i <= C; i++){
		if (i%A == 0){
			printf("OK");
			return 0;
		}
	}
	printf("NG");
return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:23: error: expected ';' before 'i'
    6 |         for (int i = B i <= C; i++){
      |                       ^~
      |                       ;
Language: C++

int main(){
	int kelipatan, awal, akhir, patokan;
	scanf("%d", &kelipatan);
	scanf("%d %d", &awal, &akhir);
	patokan = akhir/kelipatan;
	if(patokan*awal >= akhir){
		printf("OK\n");
	}	else {
		printf("NG\n");
	}
	
	
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:3:9: error: 'scanf' was not declared in this scope
    3 |         scanf("%d", &kelipatan);
      |         ^~~~~
a.cc:7:17: error: 'printf' was not declared in this scope
    7 |                 printf("OK\n");
      |                 ^~~~~~
a.cc:1:1: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
  +++ |+#include <cstdio>
    1 | int main(){
a.cc:9:17: error: 'printf' was not declared in this scope
    9 |                 printf("NG\n");
      |                 ^~~~~~
a.cc:9:17: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
Language: C++

#include <stdio.h>
 
int main() {
	int K,A,B;
	scanf("%d", &K);
	if(B-a >= K){
		puts("OK");
	}else{
		puts("NG");
	}
	
	
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:14: error: 'a' was not declared in this scope
    6 |         if(B-a >= K){
      |              ^
Language: C++

#include <stdio.h>
 
int main() {
	int K,A,B;
	scanf("%d", &K);
	if(B-A >= K){
		puts("OK");
	}else if{
		puts("NG");
	}
	
	
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:17: error: expected '(' before '{' token
    8 |         }else if{
      |                 ^
      |                 (
Language: C++

#include <stdio.h>

int main(){
   int A, K, B ;
   int flag=0 ;
   scanf("%d %d %d", &A, &K, &B);
   for(int i=A+1; i<B; i++){
       if(i%K==0) flag=1
   }
   if(flag==1){
       printf("OK\n") ;
   }
   else{
       printf("NG\n");
   }
return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:25: error: expected ';' before '}' token
    8 |        if(i%K==0) flag=1
      |                         ^
      |                         ;
    9 |    }
      |    ~
Language: C++

#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef long double ld;
typedef pair<int, int> P;
const ll mod = 1000000007;
const ll INF = 1e+14;
#define rep(i,n) for(int i=0;i<n;i++)
#define per(i,n) for(int i=n-1;i>=0;i--)
#define Rep(i,sta,n) for(int i=sta;i<n;i++)
#define rep1(i,n) for(int i=1;i<=n;i++)
#define per1(i,n) for(int i=n;i>=1;i--)
#define Rep1(i,sta,n) for(int i=sta;i<=n;i++)
#define _GLIBCXX_DEBUG
 
int main(){
  #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef long double ld;
typedef pair<int, int> P;
const ll mod = 1000000007;
const ll INF = 1e+14;
#define rep(i,n) for(int i=0;i<n;i++)
#define per(i,n) for(int i=n-1;i>=0;i--)
#define Rep(i,sta,n) for(int i=sta;i<n;i++)
#define rep1(i,n) for(int i=1;i<=n;i++)
#define per1(i,n) for(int i=n;i>=1;i--)
#define Rep1(i,sta,n) for(int i=sta;i<=n;i++)
#define _GLIBCXX_DEBUG
 
int main(){
  #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef long double ld;
typedef pair<int, int> P;
const ll mod = 1000000007;
const ll INF = 1e+14;
#define rep(i,n) for(int i=0;i<n;i++)
#define per(i,n) for(int i=n-1;i>=0;i--)
#define Rep(i,sta,n) for(int i=sta;i<n;i++)
#define rep1(i,n) for(int i=1;i<=n;i++)
#define per1(i,n) for(int i=n;i>=1;i--)
#define Rep1(i,sta,n) for(int i=sta;i<=n;i++)
#define _GLIBCXX_DEBUG
 
int main(){
  ll K; cin>>K;
  ll A,B; cin>>A>>B;
  bool judge=false;
  rep(i,B-A+1){
    if((A+i)%K==0) judge =true;
    else continue;
  }
  if(judge) cout<<"OK"<<endl;
  else cout<<"NG"<<endl;
}

 

Compiler output:
a.cc: In function 'int main()':
a.cc:32:9: warning: empty parentheses were disambiguated as a function declaration [-Wvexing-parse]
   32 | int main(){
      |         ^~
a.cc:32:9: note: remove parentheses to default-initialize a variable
   32 | int main(){
      |         ^~
      |         --
a.cc:32:9: note: or replace parentheses with braces to value-initialize a variable
a.cc:32:11: error: a function-definition is not allowed here before '{' token
   32 | int main(){
      |           ^
a.cc:58:2: error: expected '}' at end of input
   58 | }
      |  ^
a.cc:16:11: note: to match this '{'
   16 | int main(){
      |           ^
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
  int k,a,b;
  cin >> k;
  cin >> a >> b;
  int flag = 0;
  for (int i = a; i <= b; i++){
    if (i%K==0){
      flag++;
      cout << "OK" << endl;
      break;
    }
  }
  if (flag == 0){
    cout << "NG" << endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:11: error: 'K' was not declared in this scope
    9 |     if (i%K==0){
      |           ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main() {
  int K, A, B;
  cin >> K >> A >> B;
  int C = K
  for(int i = 0; i < 1000; i++) {
    if(C <= B) {
      C += K;
    }
    else {
      break;
    }
  }
  if(A <= C) {
    cout << "OK" << endl;
  }
  else {
    cout << "NG" << endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:3: error: expected ',' or ';' before 'for'
    7 |   for(int i = 0; i < 1000; i++) {
      |   ^~~
a.cc:7:18: error: 'i' was not declared in this scope
    7 |   for(int i = 0; i < 1000; i++) {
      |                  ^
Language: C

#include<stdio.h>
int main(void){
  long long i,x,k;
  scanf("%lld",&x);
  for(i=0;;i++){
    k=k+k/100
    if((int)k>=x)break;
  }
  printf("%lld",i+1);
  
 return 0; 
}


Compiler output:
main.c: In function 'main':
main.c:6:14: error: expected ';' before 'if'
    6 |     k=k+k/100
      |              ^
      |              ;
    7 |     if((int)k>=x)break;
      |     ~~
Language: C

#include<stdio.h>
int main(void){
 int i,a,b;
   scanf("%d",&i);
  scanf("%d %d"&a,&b);
  if(b-a>i){puts("OK");}
  else if(b-b%i>a){ puts("OK");}
  else {puts("NG");}
  return 0; 
}


Compiler output:
main.c: In function 'main':
main.c:5:16: error: invalid operands to binary & (have 'char *' and 'int')
    5 |   scanf("%d %d"&a,&b);
      |         ~~~~~~~^
      |         |
      |         char *
Language: C

#include<stdio.h>
int main(void){
 int i,a,b;
   scanf("%d",&i);
  scanf("%d %d"&a,&b);
  if(b-a>i){puts("Yes");}
  else if(b-b%i>a){ puts("Yes");}
  else {puts("No");}
  return 0; 
}

Compiler output:
main.c: In function 'main':
main.c:5:16: error: invalid operands to binary & (have 'char *' and 'int')
    5 |   scanf("%d %d"&a,&b);
      |         ~~~~~~~^
      |         |
      |         char *
Language: C++

/*
      author : Nishikawa
      created: 10.08.2020 16:43:04
*/

#include <bits/stdc++.h>
using namespace std;
#define rep(i,n) for(int i=0; i<n; i++)
typedef long long ll;


int main(){
    int k,a,b;
    cin >> k >> a >> b;
    for(int i=a; i<=b; i++){
        if(i%k==0){
            cout << "OK" << endl;
            return 0;
        }
    }
    cout << "NG" << endl;
    return 0;
}/*
      author : Nishikawa
      created: 10.08.2020 16:43:04
*/

#include <bits/stdc++.h>
using namespace std;
#define rep(i,n) for(int i=0; i<n; i++)
typedef long long ll;


int main(){
    int k,a,b;
    cin >> k >> a >> b;
    for(int i=a; i<=b; i++){
        if(i%k==0){
            cout << "OK" << endl;
            return 0;
        }
    }
    cout << "NG" << endl;
    return 0;
}

Compiler output:
a.cc:34:5: error: redefinition of 'int main()'
   34 | int main(){
      |     ^~~~
a.cc:12:5: note: 'int main()' previously defined here
   12 | int main(){
      |     ^~~~
Language: C++

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

i = 1
flag = False
while K * i <= B:
    if K * i >= A:
        flag = True
    i += 1

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


Compiler output:
a.cc:1:1: error: 'K' does not name a type
    1 | K = int(input())
      | ^
Language: Java

# ABC165
# We Love Golf
K = int(input())
A, B = map(int, input().split())
for x in range(A,B+1):
    if x % K == 0:
        if x >= A:
            if x <= B:
                print('OK')
                exit()
print('NG')


Compiler output:
Main.java:1: error: illegal character: '#'
# ABC165
^
Main.java:2: error: illegal character: '#'
# We Love Golf
^
Main.java:2: error: class, interface, enum, or record expected
# We Love Golf
     ^
Main.java:9: error: unclosed character literal
                print('OK')
                      ^
Main.java:9: error: unclosed character literal
                print('OK')
                         ^
Main.java:11: error: unclosed character literal
print('NG')
      ^
Main.java:11: error: unclosed character literal
print('NG')
         ^
7 errors
Language: C++

#include<iostream>
using namespace std;
int main()
{
  int k,a,b;
  cin>>k>>a>>b;
  for(int i=a;i=<b;i++)
  {
    if(i%k==0) cout<<"OK";
    return 0;
  }
  cout<<"NG";
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:17: error: expected primary-expression before '<' token
    7 |   for(int i=a;i=<b;i++)
      |                 ^
Language: C++

#include <bits/stdc++.h>
#include <string>
using namespace std;

int main(){
    int64_t a, b, k;
    strig ans ="NG";
  
    cin >> a >> b >> k;

    if( a % k == 0 || b % k == 0) ans = "OK";
    if( a / k != b / k) ans = "OK";
    cout <<  ans  << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:5: error: 'strig' was not declared in this scope
    7 |     strig ans ="NG";
      |     ^~~~~
a.cc:11:35: error: 'ans' was not declared in this scope; did you mean 'abs'?
   11 |     if( a % k == 0 || b % k == 0) ans = "OK";
      |                                   ^~~
      |                                   abs
a.cc:12:25: error: 'ans' was not declared in this scope; did you mean 'abs'?
   12 |     if( a / k != b / k) ans = "OK";
      |                         ^~~
      |                         abs
a.cc:13:14: error: 'ans' was not declared in this scope; did you mean 'abs'?
   13 |     cout <<  ans  << endl;
      |              ^~~
      |              abs
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main(){
  int k,a,b;
  cin>>k>>a>>b;
  if (a%k==0 ||b%k==0){
    cout<<"OK"<<endl;}
  else if (b/k-a/k>=1){
    cout<<"OK"<<endl;}
  else{ cout<<"NG"<<enndl;}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:21: error: 'enndl' was not declared in this scope
   10 |   else{ cout<<"NG"<<enndl;}
      |                     ^~~~~
Language: C++

#include <bits/stdc++.h>
using namispace std;
int main(){
  int k,a,b;
  cin>>k>>a>>b;
  if (a%k==0 ||b%k==0){
    cout<<"OK"<<endl;}
  else if (b/k-a/k>=1){
    cout<<"OK"<<endl;}
  else{ cout<<"NG"<<enndl;}
}

Compiler output:
a.cc:2:7: error: expected nested-name-specifier before 'namispace'
    2 | using namispace std;
      |       ^~~~~~~~~
a.cc: In function 'int main()':
a.cc:5:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    5 |   cin>>k>>a>>b;
      |   ^~~
      |   std::cin
In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:146,
                 from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:7:5: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    7 |     cout<<"OK"<<endl;}
      |     ^~~~
      |     std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:7:17: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    7 |     cout<<"OK"<<endl;}
      |                 ^~~~
      |                 std::endl
In file included from /usr/include/c++/14/istream:41,
                 from /usr/include/c++/14/sstream:40,
                 from /usr/include/c++/14/complex:45,
                 from /usr/include/c++/14/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:127:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
a.cc:9:5: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    9 |     cout<<"OK"<<endl;}
      |     ^~~~
      |     std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:9:17: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    9 |     cout<<"OK"<<endl;}
      |                 ^~~~
      |                 std::endl
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
a.cc:10:9: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   10 |   else{ cout<<"NG"<<enndl;}
      |         ^~~~
      |         std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:10:21: error: 'enndl' was not declared in this scope
   10 |   else{ cout<<"NG"<<enndl;}
      |                     ^~~~~
Language: C++

#include <iostream>
using namespace std;
int main(void){
    
    int K;
    int >> A >> B;
    cin >> K;
    cin >> A >> B;
    
    int K_bai = (B / K) * K;
    
    if(K_bai >= A){
        cout << "Yes" << endl;
    }
    else{
        cout << "No" << endl;
    }


}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:9: error: expected unqualified-id before '>>' token
    6 |     int >> A >> B;
      |         ^~
a.cc:8:12: error: 'A' was not declared in this scope
    8 |     cin >> A >> B;
      |            ^
a.cc:8:17: error: 'B' was not declared in this scope
    8 |     cin >> A >> B;
      |                 ^
Language: C++

//بِسْمِ ٱللَّٰهِ ٱلرَّحْمَٰنِ ٱلرَّحِيمِ
#include <bits/stdc++.h>

using namespace std;

typedef long long ll;
typedef unsigned long long ull;
typedef long double ld;
typedef double db;

#define endl "\n"

const int MOD = 1000000007;


int main()
{
    ios::sync_with_stdio(0);cin.tie(0);
    int a, b, c;
    cin >>a >> b >> c;
    
    for(int i = b; i < c ; i++){
        if(i % a == 0){
            cout << "OK" << endl;
            break;
        }
        else{
            cout << "NG" << endl;
            break;
        }
    }
        
    else
        
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:33:5: error: 'else' without a previous 'if'
   33 |     else
      |     ^~~~
Language: Java

import java.util.*;

public class Mian{
  public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int K = sc.nextInt();
		int A = sc.nextInt();
		int B = sc.nextInt();
		int num = 0;
		String str = null;
		for(int i = A;i <= B;i++) {
			if(num / K == 0) {
				str = "OK";
			}
		}
		if(str.equals("OK")) {
			System.out.println("OK");
		}else {
			System.out.println("NG");
		}
	}
}


Compiler output:
Main.java:3: error: class Mian is public, should be declared in a file named Mian.java
public class Mian{
       ^
1 error
Language: C++

#include <bits/stdc++.h>
#define rep(i,n) for (int i = 0; i < (n); ++i)
using namespace std;
//using ll = long long;
//using P = pair<int,int>;

int main(){
  int k,a,b,counts=0;
  cin >> k >> a >> b;
  for(int i = a; i<b; i++){
   if(i%k == 0) counts++ 
  }
 if(counts != 0) cout << "OK" << endl;
  else cout << "NG" << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:25: error: expected ';' before '}' token
   11 |    if(i%k == 0) counts++
      |                         ^
      |                         ;
   12 |   }
      |   ~
Language: C++

#include <bits/stdc++.h>
#define rep(i,n) for (int i = 0; i < (n); ++i)
using namespace std;
//using ll = long long;
//using P = pair<int,int>;

int main(){
  int k,a,b,counts=0;
  cin >> k >> a >> b;
  for(int i = a; i<b; i++){
   if(i%k == 0) counts++ 
  }
 if(counts !=) cout << "OK" << endl;
  else cout << "NG" << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:25: error: expected ';' before '}' token
   11 |    if(i%k == 0) counts++
      |                         ^
      |                         ;
   12 |   }
      |   ~                      
a.cc:13:14: error: expected primary-expression before ')' token
   13 |  if(counts !=) cout << "OK" << endl;
      |              ^
Language: C++

#include<iostream>
#include<bits/stdc++.h>
using namespace std;
int main()
{
  int a,b,k;
  cin>>k;
  cin>>a>>b;
  for(int i=a,i<=b;i++)
  {
    if(i%k==0)
    {
      cout<<"OK\n";
      break;
    }
    else
      cout<<"NG\n";
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:16: error: expected ';' before '<=' token
    9 |   for(int i=a,i<=b;i++)
      |                ^~
      |                ;
a.cc:9:16: error: expected primary-expression before '<=' token
    9 |   for(int i=a,i<=b;i++)
      |                ^~
Language: C

#include <stdio.h>
int main(){
  int K, A, B, n = 0;
  scanf("%d %d %d", &K, &A, &B);
  for (int i = A; i <= B; i++) {
    if (i % K == 0) {
      n += 1;
    }
  if (n >= 1) {
    printf("OK");
  }
  else {
    printf("NG");
  }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:16:1: error: expected declaration or statement at end of input
   16 | }
      | ^
Language: C

#include <stdio.h>
int main(){
  int K, A, B, n = 0;
  scanf("%d %d %d", &K, &A, &B);
  for (i = A; i <= B; i++) {
    if (i % K == 0) {
      n += 1;
    }
  if (n >= 1) {
    printf("OK");
  }
  else {
    printf("NG");
  }
  return 0;
  }

Compiler output:
main.c: In function 'main':
main.c:5:8: error: 'i' undeclared (first use in this function)
    5 |   for (i = A; i <= B; i++) {
      |        ^
main.c:5:8: note: each undeclared identifier is reported only once for each function it appears in
main.c:16:3: error: expected declaration or statement at end of input
   16 |   }
      |   ^
Language: C++

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


Compiler output:
a.cc:8:22: warning: multi-character character constant [-Wmultichar]
    8 | if ans==True : print('OK')
      |                      ^~~~
a.cc:9:14: warning: multi-character character constant [-Wmultichar]
    9 | else : print('NG')
      |              ^~~~
a.cc:1:1: error: 'k' does not name a type
    1 | k = int(input())
      | ^
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int K,A,B;
  cin>>K>>A>>B;
  for(int i=0; i<K; i++){
    if(A%k==0){
      cout<<"OK"<<endl;
      break;
    }
    A+=1;
    if(A>B){
      cout<<"NG"<<endl;
      break;
    }
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:10: error: 'k' was not declared in this scope
    8 |     if(A%k==0){
      |          ^
Language: C++

using namespace std;
int main() {
  int K, A, B;
  cin >> K >> A >> B;
  for (A;A <= B;A++) {
  if (A % K == 0) {
    cout << "OK" << endl;
    return 0;
  }
  }
  cout << "NG" << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:4:3: error: 'cin' was not declared in this scope
    4 |   cin >> K >> A >> B;
      |   ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
  +++ |+#include <iostream>
    1 | using namespace std;
a.cc:7:5: error: 'cout' was not declared in this scope
    7 |     cout << "OK" << endl;
      |     ^~~~
a.cc:7:5: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:7:21: error: 'endl' was not declared in this scope
    7 |     cout << "OK" << endl;
      |                     ^~~~
a.cc:1:1: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
  +++ |+#include <ostream>
    1 | using namespace std;
a.cc:11:3: error: 'cout' was not declared in this scope
   11 |   cout << "NG" << endl;
      |   ^~~~
a.cc:11:3: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:11:19: error: 'endl' was not declared in this scope
   11 |   cout << "NG" << endl;
      |                   ^~~~
a.cc:11:19: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int k, a,b,counts =0;
  cin >> k >> a >> b;
  for(int i = 0; i < 142; i++){
    if( k*i => a && k*i =< b){
      counts++;
    }
  }
  if(counts == 0){
    cout << "NG" << endl;
  }
  else{
    cout << "OK" <<endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:14: error: expected primary-expression before '>' token
    8 |     if( k*i => a && k*i =< b){
      |              ^
a.cc:8:26: error: expected primary-expression before '<' token
    8 |     if( k*i => a && k*i =< b){
      |                          ^
Language: C++

#include<iostream>
#include<string>
using namespace std;
int main() {
	int k, a, b; cin >> k >> a >> b;
	string ans="NG"
	if (b - a >= k) ans = "OK";
	else {
		for (int i = b - a; i < b; i++) {
			if (i % k == 0) {
				ans = "OK";
				break;
			}
		}
	}
	cout << ans << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:9: error: expected ',' or ';' before 'if'
    7 |         if (b - a >= k) ans = "OK";
      |         ^~
a.cc:8:9: error: 'else' without a previous 'if'
    8 |         else {
      |         ^~~~
Language: C++

#include <string>
#include <bits/stdc++.h>
#define For(i, n) for (int i = 0; i < (int)(n); i++)
using namespace std;

int main() {
  int X,A,B;
  cin>>X>>A>>B;
  for(int i=A;i<=B;i++){
    if(i%X==0){
      Cout<<"OK"<<endl;
      return 0;
    }
  }
  cout<<"NG"<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:7: error: 'Cout' was not declared in this scope
   11 |       Cout<<"OK"<<endl;
      |       ^~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main() {
  int K, A, B;
  cin >> K >> A >> B;
  bool ans = false;
  for (int i = 1; i <= 1000; i++) {
    if (K * i >= A && K * i <= B)
      ans = true;
    if (ans == ture) {
      cout << "YES" << endl;
      break;
    }
  }
  if (ans == false)
    cout << "NO" << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:11:16: error: 'ture' was not declared in this scope
   11 |     if (ans == ture) {
      |                ^~~~
Language: Java

import java.util.Scanner;
public class Main
{
  public static void main(String[] args)
  {
    Scanner sc = new Scanner(System.in);
    int x = sc.nextint();
    int y  = sc.nextInt();
    int z  = sc.nextInt(); 
    int result = y % 10;
    int result1 = z % 10;
    if(x == result)
      System.out.println("OK");
    else
       System.out.println("NG");
    if(x == result1)
      System.out.println("OK");
    else
       System.out.println("NG");
    
    
  }
}


Compiler output:
Main.java:7: error: cannot find symbol
    int x = sc.nextint();
              ^
  symbol:   method nextint()
  location: variable sc of type Scanner
1 error
Language: C++

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


Compiler output:
a.cc:8:22: warning: multi-character character constant [-Wmultichar]
    8 | if ans==True : print('OK')
      |                      ^~~~
a.cc:9:14: warning: multi-character character constant [-Wmultichar]
    9 | else : print('NG')
      |              ^~~~
a.cc:1:1: error: 'k' does not name a type
    1 | k = int(input)
      | ^
Language: C

#include <iostream>
using namespace std;
int main(){
    int k,a,b;
    cin>>k>>a>>b;
    int rem = a%k;
    if(rem!=0)
        rem=k-rem;
    if(rem>b-a){
        cout<<"NG"<<endl;
    }else{
        cout<<"OK"<<endl;
    }
    return 0;
}

Compiler output:
main.c:1:10: fatal error: iostream: No such file or directory
    1 | #include <iostream>
      |          ^~~~~~~~~~
compilation terminated.
Language: C++

#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 ; 
     break ; 
   else if (i < K){
     cout << "NG" << endl ; 
   }
   }
    cout << "NG" << endl ; 
  }
  
  
}


Compiler output:
a.cc: In function 'int main()':
a.cc:14:4: error: expected '}' before 'else'
   14 |    else if (i < K){
      |    ^~~~
a.cc:11:17: note: to match this '{'
   11 |    if(i % K ==0){
      |                 ^
a.cc: At global scope:
a.cc:22:1: error: expected declaration before '}' token
   22 | }
      | ^
Language: C++

#include<bits/stdc++>
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 ; 
   }
    cout << "NG" << endl ; 
  }
  
  
}

Compiler output:
a.cc:1:9: fatal error: bits/stdc++: No such file or directory
    1 | #include<bits/stdc++>
      |         ^~~~~~~~~~~~~
compilation terminated.
Language: C

#include <iostream>
#include <fstream>
#include <vector>
#include <map>
#include <cmath>
#include <algorithm>
#include <iomanip>
#include <numeric>
#include <queue>
using namespace std;
 
#define LOCAL  1
#define UPLOAD 2
 
#define ll long long
const long long INF = 1LL << 60;
 
template <class T = long long> T input(){T x;cin >> x;return x;}
template <class T> void output(T x){cout << x << endl;}
#define debug(x) cerr << #x<< ": " << x<< '\n';
#define debugBit(x,n) cerr << #x<< ": " << std::bitset<n>(x) << '\n';
#define REP(i,M) for(int i=0;i<M;i++)
 
template<class T> inline bool chmin(T& a, T b) {if (a > b) {a = b;return true;}return false;}
template<class T> inline bool chmax(T& a, T b) {if (a < b) {a = b;return true;}return false;}
ll gcd(ll x,ll y){return y?gcd(y,x%y):x;}
 
int main()
{
#if ENVIRONMENT == LOCAL
    std::ifstream in("input.txt");
    std::cin.rdbuf(in.rdbuf());
#endif
  
  ll K = input();
  ll A = input();
  ll B = input();

  float f = (float)A / (float)K;
  float f2 = (float)B / (float)K;
  ll answer = ceil(f);

  if(answer <= f2){
    output("OK");
  }
  else{
    output("NG");
  }
  
  return 0;
}

Compiler output:
main.c:1:10: fatal error: iostream: No such file or directory
    1 | #include <iostream>
      |          ^~~~~~~~~~
compilation terminated.
Language: C++

#include<bits/stdc++.h>
#define all(x) x.begin(), x.end()
#define pb push_back
using namespace std;
using ll = long long;
const int maxn = 1<<18;
signed main() {
	cin.tie(0)->sync_with_stdio(0);
int n, a, b;
cin >> n >> a >> b;
while(a <= b) if(a%n == 0) return cout << "OK"; else a++;
cout << "NG";	
return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:11:40: error: cannot convert 'std::basic_ostream<char>' to 'int' in return
   11 | while(a <= b) if(a%n == 0) return cout << "OK"; else a++;
      |                                   ~~~~~^~~~~~~
      |                                        |
      |                                        std::basic_ostream<char>
Language: C++

#pragma GCC optimize("O2")
#pragma GCC target("avx,avx2,sse,sse2,ssse3,sse4.1,sse4.2,popcnt,tune=native")
#include<bits/stdc++.h>
#define all(x) x.begin(), x.end()
#define pb push_back
using namespace std;
using ll = long long;
const int maxn = 1<<18;
signed main() {
	cin.tie(0)->sync_with_stdio(0);
int n, a, b;
cin >> n >> a >> b;
while(a <= b) if(a%n == 0) return cout << "OK"; else a++;
cout << "NG";	
return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:13:40: error: cannot convert 'std::basic_ostream<char>' to 'int' in return
   13 | while(a <= b) if(a%n == 0) return cout << "OK"; else a++;
      |                                   ~~~~~^~~~~~~
      |                                        |
      |                                        std::basic_ostream<char>
Language: C++

#pragma GCC optimize("O2")
#pragma GCC target("avx,avx2,sse,sse2,ssse3,sse4.1,sse4.2,popcnt,tune=native")
#include<bits/stdc++.h>
#define all(x) x.begin(), x.end()
#define pb push_back
using namespace std;
using ll = long long;
const int maxn = 1<<18;
signed main() {
	cin.tie(0)->sync_with_stdio(0);
int n, a, b;
cin >> n >> a >> b;
while(a <= b) if(a%n == 0) return cout << "YES"; else a++;
cout << "NO";	
return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:13:40: error: cannot convert 'std::basic_ostream<char>' to 'int' in return
   13 | while(a <= b) if(a%n == 0) return cout << "YES"; else a++;
      |                                   ~~~~~^~~~~~~~
      |                                        |
      |                                        std::basic_ostream<char>
Language: C++

#include <bits/stdc++.h>

using namespace std;

int main() {
	int a, b, k;
	cin >> a >> b;

	int res = (b - b % k);
	if (res < a) {
		cout << "NG";
	} else cout << "OK;
}


Compiler output:
a.cc:12:24: warning: missing terminating " character
   12 |         } else cout << "OK;
      |                        ^
a.cc:12:24: error: missing terminating " character
   12 |         } else cout << "OK;
      |                        ^~~~
a.cc: In function 'int main()':
a.cc:13:1: error: expected primary-expression before '}' token
   13 | }
      | ^
Language: C++

using namespace std;
int main(void)
{
    short int K,A,B,count=0;
    cin>>K;
    cin>>A>>B;

    for(int i=A;i<=B;i++)
    {
        if(i%K==0)
        {
            count=1;
            break;
        }
    }


    if(count==1) cout<<"OK"<<endl;
    else cout<<"NG"<<endl;


}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:5: error: 'cin' was not declared in this scope
    5 |     cin>>K;
      |     ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
  +++ |+#include <iostream>
    1 | using namespace std;
a.cc:18:18: error: 'cout' was not declared in this scope
   18 |     if(count==1) cout<<"OK"<<endl;
      |                  ^~~~
a.cc:18:18: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:18:30: error: 'endl' was not declared in this scope
   18 |     if(count==1) cout<<"OK"<<endl;
      |                              ^~~~
a.cc:1:1: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
  +++ |+#include <ostream>
    1 | using namespace std;
a.cc:19:10: error: 'cout' was not declared in this scope
   19 |     else cout<<"NG"<<endl;
      |          ^~~~
a.cc:19:10: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:19:22: error: 'endl' was not declared in this scope
   19 |     else cout<<"NG"<<endl;
      |                      ^~~~
a.cc:19:22: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{int a,b,k;
 cin>>k>>a>>b;
 for(int i=a;i<=b;i++){
   if( i % k == 0)
   cout << "OK" << endl;
 }
 else
  cout << "NG" << endl;
return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:2: error: 'else' without a previous 'if'
   10 |  else
      |  ^~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{int a,b,k;
 cin>>k>>a>>b;
 for(int i=a;i<=b;i++)
   if( i % k == 0){cout << "OK" << endl; return 0;}
  }
  cout << "NG" << endl;
return 0;
}

Compiler output:
a.cc:9:3: error: 'cout' does not name a type
    9 |   cout << "NG" << endl;
      |   ^~~~
a.cc:10:1: error: expected unqualified-id before 'return'
   10 | return 0;
      | ^~~~~~
a.cc:11:1: error: expected declaration before '}' token
   11 | }
      | ^
Language: C

#include<stdio.h>
int main(void)
{
    int K,A,B;
  
    scanf("%d",&K);
    scanf("%d%d",&A,&B);
  
    for(i=0;i<=B-A;i++){
      if((A+i)%4==0){
        printf("OK\n");
        return 0;
      }
    }
  
    printf("NG\n");
      
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:9:9: error: 'i' undeclared (first use in this function)
    9 |     for(i=0;i<=B-A;i++){
      |         ^
main.c:9:9: note: each undeclared identifier is reported only once for each function it appears in
Language: C++

//#include<bits/stdc++.h> using namespace std;
#include<iostream>
using namespace std;
#include<algorithm>
#include<map>
#include<vector>
#include<set>
#include<stack>
#include<queue> //priority_queue inside queue
#include<deque>
#define fast ios_base::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL);
#define nl '\n'
typedef long long ll;
typedef unsigned long long ull;
#define f(i,start,end) for(i=start;i<=end;i++)
#define min_heap priority_queue<int, vector<int>, greater<int> >
#define max_heap priority_queue<int>

bool isPrime(int n)
{
    for(int i=2; i*i<=n; i++)
    {
        if(n%i==0) return false;
    }
    return true;
} //returns true if prime!


int main()
{
    fast;
//int t=0,tc=0; cin >> tc; f(t,1,tc) //testcases
    {
        int n; cin >> n;
        int a,b; cin >> a >> b;
        for(int i=a; i<=b; i++)
        {
            if(i%k==0){ cout << "OK"; return 0; }
        }
        cout << "NG";
    }
    return 0;
}
    


Compiler output:
a.cc: In function 'int main()':
a.cc:38:18: error: 'k' was not declared in this scope
   38 |             if(i%k==0){ cout << "OK"; return 0; }
      |                  ^
Language: C

#include<stdio.h>

int main()
{
    int a, b, k, i, j;
    int flg = 0;
    scanf("%d", &k);
    scanf("%d %d", &a, &b);
    
    for (i = a; i <= b; i++)
    {
        j = i % k;
        if(j == 0)
        {
            printf("OK");
            flg = 1
            break;
        }
    }
    if(flg == 0)
    {
        printf("NO");   
    }
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:16:20: error: expected ';' before 'break'
   16 |             flg = 1
      |                    ^
      |                    ;
   17 |             break;
      |             ~~~~~
Language: C

#include<stdio.h>

int main()
{
    int a, b, k, i, j;
    int flg = 0;
    scanf("%d", &k);
    scanf("%d %d", &a, &b);
    
    for (i = a; i <= b; i++)
    {
        j = i % k;
        if(j == 0)
        {
            printf("OK");
            flg = 1
            break;
        }
    }
    if flg == 0
    {
        printf("NO");   
    }
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:16:20: error: expected ';' before 'break'
   16 |             flg = 1
      |                    ^
      |                    ;
   17 |             break;
      |             ~~~~~   
main.c:20:8: error: expected '(' before 'flg'
   20 |     if flg == 0
      |        ^~~
      |        (
Language: C

int main()
{
    int a, b, k, i, j;
    int flg = 0;
    scanf("%d", &k);
    scanf("%d %d", &a, &b);
    
    for (i = a; i <= b; i++)
    {
        j = i % k;
        if(j == 0)
        {
            printf("OK");
            flg = 1
            break;
        }
    }
    if flg == 0
    {
        printf("NO");   
    }
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:5: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
    5 |     scanf("%d", &k);
      |     ^~~~~
main.c:1:1: note: include '<stdio.h>' or provide a declaration of 'scanf'
  +++ |+#include <stdio.h>
    1 | int main()
main.c:5:5: warning: incompatible implicit declaration of built-in function 'scanf' [-Wbuiltin-declaration-mismatch]
    5 |     scanf("%d", &k);
      |     ^~~~~
main.c:5:5: note: include '<stdio.h>' or provide a declaration of 'scanf'
main.c:13:13: error: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
   13 |             printf("OK");
      |             ^~~~~~
main.c:13:13: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:13:13: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
main.c:13:13: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:14:20: error: expected ';' before 'break'
   14 |             flg = 1
      |                    ^
      |                    ;
   15 |             break;
      |             ~~~~~   
main.c:18:8: error: expected '(' before 'flg'
   18 |     if flg == 0
      |        ^~~
      |        (
Language: C

#include<stdio.h>

int main()
{
    int a, b, k, i, j;
    scanf("%d", &k);
    scanf("%d %d", &a &b);
    
    for (i = a; i <= b; i++)
    {
        j = i % k;
        if (j == 0)
        {
            printf("OK");
        }
        else
        {
            printf("NO");
        }
    }
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:7:23: error: invalid operands to binary & (have 'int *' and 'int')
    7 |     scanf("%d %d", &a &b);
      |                    ~~ ^
      |                    |
      |                    int *
Language: C

#include<stdio.h>
#include<math.h>
int main()
{
    int t;
    scanf("%d",&t);
  int a,b;int c=0;
  scanf("%d%d,&a,&b);
        for(int i=a;i<=b;i++)
        {
          if(i%t==0)
          {
            ++c;break;
          }
        }
        if(c==0)
        printf("NG");
        else
        printf("OK");
        }

Compiler output:
main.c: In function 'main':
main.c:8:9: warning: missing terminating " character
    8 |   scanf("%d%d,&a,&b);
      |         ^
main.c:8:9: error: missing terminating " character
    8 |   scanf("%d%d,&a,&b);
      |         ^~~~~~~~~~~~~
main.c:9:9: error: expected expression before 'for'
    9 |         for(int i=a;i<=b;i++)
      |         ^~~
main.c:19:22: error: expected ';' before '}' token
   19 |         printf("OK");
      |                      ^
      |                      ;
   20 |         }
      |         ~
Language: C++

#include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)

int main() {
  int K,A,B;
 cin>>K>>A>>B;

  string Ans="NG"
    
  for(int i=A;i<=B;i++){
    if(i%K==0){Ans="OK";break;}
  }
  cout<<Ans<<endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:11:3: error: expected ',' or ';' before 'for'
   11 |   for(int i=A;i<=B;i++){
      |   ^~~
a.cc:11:15: error: 'i' was not declared in this scope
   11 |   for(int i=A;i<=B;i++){
      |               ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)

int main() {
  int K,A,B;
 cin>>K>>A>>B;

  string Ans="NG"
    
  for(int i=A;i<=B,i++){
    if(i%K==0){Ans="OK";break;}
  }
  cout<<Ans<<endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:11:3: error: expected ',' or ';' before 'for'
   11 |   for(int i=A;i<=B,i++){
      |   ^~~
a.cc:11:15: error: 'i' was not declared in this scope
   11 |   for(int i=A;i<=B,i++){
      |               ^
Language: C++

include<bits/stdc++.h>
using namespace std;
int main()
{
  string j="NG";
  int k,a,b;
  cin>>k>>a>>b;
  for(int c=0; c<=1000; c++){
    if(a<=k*c&&k*c<=b){
      j="OK";
    }
  }
  cout<<j<<endl;
}

Compiler output:
a.cc:1:1: error: 'include' does not name a type
    1 | include<bits/stdc++.h>
      | ^~~~~~~
a.cc: In function 'int main()':
a.cc:5:3: error: 'string' was not declared in this scope
    5 |   string j="NG";
      |   ^~~~~~
a.cc:7:3: error: 'cin' was not declared in this scope
    7 |   cin>>k>>a>>b;
      |   ^~~
a.cc:10:7: error: 'j' was not declared in this scope
   10 |       j="OK";
      |       ^
a.cc:13:3: error: 'cout' was not declared in this scope
   13 |   cout<<j<<endl;
      |   ^~~~
a.cc:13:9: error: 'j' was not declared in this scope
   13 |   cout<<j<<endl;
      |         ^
a.cc:13:12: error: 'endl' was not declared in this scope
   13 |   cout<<j<<endl;
      |            ^~~~
Language: C++

include<bits/stdc++.h>
using namespace std;
int main()
{
  string j="NG";
  int k,a,b;
  cin>>k>>a>>b;
  for(int c=o; c<=1000; c++){
    if(a<=k*c&&k*c<=b){
      j="OK";
    }
  }
  cout<<j<<endl;
}
      

Compiler output:
a.cc:1:1: error: 'include' does not name a type
    1 | include<bits/stdc++.h>
      | ^~~~~~~
a.cc: In function 'int main()':
a.cc:5:3: error: 'string' was not declared in this scope
    5 |   string j="NG";
      |   ^~~~~~
a.cc:7:3: error: 'cin' was not declared in this scope
    7 |   cin>>k>>a>>b;
      |   ^~~
a.cc:8:13: error: 'o' was not declared in this scope
    8 |   for(int c=o; c<=1000; c++){
      |             ^
a.cc:10:7: error: 'j' was not declared in this scope
   10 |       j="OK";
      |       ^
a.cc:13:3: error: 'cout' was not declared in this scope
   13 |   cout<<j<<endl;
      |   ^~~~
a.cc:13:9: error: 'j' was not declared in this scope
   13 |   cout<<j<<endl;
      |         ^
a.cc:13:12: error: 'endl' was not declared in this scope
   13 |   cout<<j<<endl;
      |            ^~~~
Language: C++

#include<bits/stdc++.h>
#define fast ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);
#define ll long long
using namespace std;
void solve()
{
    int k,a,b;
    cin>>k>>a>>b;
    else if((b/k)*k>=a)
    {
        cout<<"OK";
    }
    else cout<<"NG";
}

int main()
{
    fast;
    int t;
    solve();
}


Compiler output:
a.cc: In function 'void solve()':
a.cc:9:5: error: 'else' without a previous 'if'
    9 |     else if((b/k)*k>=a)
      |     ^~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
  int A,B,K;
  cin>>K;
  cin>>A>>B;
  if(K>=1 && K<=1000 && A>=1 && B>=A && B<=1000 && (B-A)%k==0)
      cout<<"OK"<<endl;
  else
    cout<<"NG"<<endl;

  return 0;}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:58: error: 'k' was not declared in this scope
    7 |   if(K>=1 && K<=1000 && A>=1 && B>=A && B<=1000 && (B-A)%k==0)
      |                                                          ^
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
  int A,B,K;
  cin>>K;
  cin>>A>>B;
  if(k>=1 && k<=1000 && A>=1 && B>=A && B<=1000)
      cout<<"OK"<<endl;
  else
    cout<<"NG"<<endl;
  
  return 0;}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:6: error: 'k' was not declared in this scope
    7 |   if(k>=1 && k<=1000 && A>=1 && B>=A && B<=1000)
      |      ^
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
  int A,B,K;
  cin>>K;
  cin>>A>>B;
  if(k>=1 && k<=1000)
    if(A>=1 && B>=A && B<=1000)
      cout<<"OK"<<endl;
  else
    cout<<"NG"<<endl;
  
  return 0;}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:6: error: 'k' was not declared in this scope
    7 |   if(k>=1 && k<=1000)
      |      ^
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main(){
  
  int a,b,c;
  cin >> a >> b >> c;
  
  for(int i=b;i<=b && i>=c;i++){
    if( i%a == 0 ){
    
      cout << "OK" << endl;
      
    }
  }
    
    cout << "NO" << endl;
    
  }
  
}


Compiler output:
a.cc:21:1: error: expected declaration before '}' token
   21 | }
      | ^
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main(){
  
  int a,b,c,count = 0;
  cin >> a >> b >> c;
  
  for(int i=b;i<=b && i>=c;i++){
    if( i%a == 0 ){
    
      cout << "OK" << endl;
      
    }
  }
    
    cout << "NO" << endl;
    
  }
  
}


Compiler output:
a.cc:21:1: error: expected declaration before '}' token
   21 | }
      | ^
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main(){
  
  int a,b,c,d,count = 0;
  cin >> a >> b >> c;
  d = c-b;
  
  for(int i=b;i<d;i++){
    if( i%a == 0 ){
    
      count++;
      
    }
    
  if( count > 0 ){
    
    cout << "OK" << endl;
    
  }
  
  else{
    
    cout << "NO" << endl;
    
  }
  
}


Compiler output:
a.cc: In function 'int main()':
a.cc:29:2: error: expected '}' at end of input
   29 | }
      |  ^
a.cc:4:11: note: to match this '{'
    4 | int main(){
      |           ^
Language: C

#include<stdio.h>
int main(void)
{
	int K,A,B,flg,i;
	scanf("%d %d %d",&K,&A,&B);
	flg=0;
	for(i=A;i<=B;i++){
		if(i%k==0){
			flg=1;
		}
	}
	if(flg==1){
		printf("OK\n");
	}
	else{
		printf("NG\n");
	}
	return 0;
}

			

Compiler output:
main.c: In function 'main':
main.c:8:22: error: 'k' undeclared (first use in this function)
    8 |                 if(i%k==0){
      |                      ^
main.c:8:22: note: each undeclared identifier is reported only once for each function it appears in