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

#include<stdio.h>
#define _CRT_SECURE_NO_WARNINGS 1
#define CAKE 4 //ケーキは4ドル
#define DONUT 7 //ドーナツは7ドル

int main(void)
{
	//変数を定義
	int n, flag = 0;
	//入力
	scanf_s("%d", &n);

	//変数flagがカウントされたらYes。されなかったらNo。
	for (int i = 0; i <= 100 ;i++) {
		for (int j = 0; j <= 100 ; j++) {
			//購入の全通りを試す
			if (n == CAKE * i + DONUT * j) {
				flag++;
				break;
			}
			//入力した値段を超えたらbreak
			else if(n < CAKE * i + DONUT * j){
				break;
			}
		}
	}

	//変数flagが0かどうかで出力を分岐
	if (flag) {
		printf("Yes\n");
	}
	else {
		printf("No\n");
	}

	return 0;
}



Compiler output:
a.cc: In function 'int main()':
a.cc:11:9: error: 'scanf_s' was not declared in this scope; did you mean 'scanf'?
   11 |         scanf_s("%d", &n);
      |         ^~~~~~~
      |         scanf
Language: C++

include <stdio.h>

int main(void){
	int N,i,j,x=4,y=7,a=0,flag=0;
	scanf("%d",&N);
	for(i = 1; i < 101; i++){ //極限値1から101までをiでfor文で回す
		for(j = 1; j < 101; j++){ //極限値1から101までをjでfor文を回す
			a= (x * i) + (y * j); //aにjから順に回して左記の式に入れていく
			
			if(N % 4 == 0){ //Nが4で割り切れるなら、括弧内の処理を実行
				flag = 1; //flagを1する
			}
			else if(N % 7 == 0){ //Nが7で割り切れるなら、括弧内の処理を実行
				flag = 1; //flagを1する
			}
			else if(N % a == 0){ //Nをaの式で割りきれる場合、括弧内を実行
				flag = 1; //flagを1する
			}
			else{ //それ以外ならflagは0のまま
			}
		}
	}
	flag ? printf("Yes\n") : printf("No\n"); //flagを1か0かでYesかNoを判定する
	return 0;
}

Compiler output:
a.cc:1:1: error: 'include' does not name a type
    1 | include <stdio.h>
      | ^~~~~~~
Language: C++

#include <iostream>
using namespace std;
 //Compiler version g++ 6.3.0

 int main()
 {
 	int a,b;
 	cin >> a >> b;
 	if(a%b=0){
 		cout << 0 << endl;
 	}else{
 		cout << 1 << endl;
 	}
 }

Compiler output:
a.cc: In function 'int main()':
a.cc:9:13: error: lvalue required as left operand of assignment
    9 |         if(a%b=0){
      |            ~^~
Language: Java

import java.util.*;
class Main{
	static Scanner scan = new Scanner(System.in);
	static void crackers(){
		int n = scan.nextInt(), k = scan.nextInt();
		if(n/k==0)
			int m = 0;
		else
			int m = 1;
		System.out.println(m);
	}
	public static void main(String[] argv){
		crackers();
	}
}

Compiler output:
Main.java:7: error: variable declaration not allowed here
			int m = 0;
			    ^
Main.java:9: error: variable declaration not allowed here
			int m = 1;
			    ^
2 errors
Language: Java

import java.util.*;
class Main{
	static Scanner scan = new Scanner(System.out);
	static void crackers(){
		int n = scan.nextInt(), k = scan.nextInt();
		if(n/k==0)
			System.out.println("0");
		else
			System.out.println("1");
	}
	public static void main(String[] argv){
		crackers();
	}
}

Compiler output:
Main.java:3: error: no suitable constructor found for Scanner(PrintStream)
	static Scanner scan = new Scanner(System.out);
	                      ^
    constructor Scanner.Scanner(Readable) is not applicable
      (argument mismatch; PrintStream cannot be converted to Readable)
    constructor Scanner.Scanner(InputStream) is not applicable
      (argument mismatch; PrintStream cannot be converted to InputStream)
    constructor Scanner.Scanner(File) is not applicable
      (argument mismatch; PrintStream cannot be converted to File)
    constructor Scanner.Scanner(Path) is not applicable
      (argument mismatch; PrintStream cannot be converted to Path)
    constructor Scanner.Scanner(String) is not applicable
      (argument mismatch; PrintStream cannot be converted to String)
    constructor Scanner.Scanner(ReadableByteChannel) is not applicable
      (argument mismatch; PrintStream cannot be converted to ReadableByteChannel)
Note: Some messages have been simplified; recompile with -Xdiags:verbose to get full output
1 error
Language: Java

import java.util.*;
class Begin106{
	static Scanner scan = new Scanner(System.out);
	static void crackers(){
		int n = scan.nextInt(), k = scan.nextInt();
		if(n/k==0)
			System.out.println("0");
		else
			System.out.println("1");
	}
	public static void main(String[] argv){
		crackers();
	}
}

Compiler output:
Main.java:3: error: no suitable constructor found for Scanner(PrintStream)
	static Scanner scan = new Scanner(System.out);
	                      ^
    constructor Scanner.Scanner(Readable) is not applicable
      (argument mismatch; PrintStream cannot be converted to Readable)
    constructor Scanner.Scanner(InputStream) is not applicable
      (argument mismatch; PrintStream cannot be converted to InputStream)
    constructor Scanner.Scanner(File) is not applicable
      (argument mismatch; PrintStream cannot be converted to File)
    constructor Scanner.Scanner(Path) is not applicable
      (argument mismatch; PrintStream cannot be converted to Path)
    constructor Scanner.Scanner(String) is not applicable
      (argument mismatch; PrintStream cannot be converted to String)
    constructor Scanner.Scanner(ReadableByteChannel) is not applicable
      (argument mismatch; PrintStream cannot be converted to ReadableByteChannel)
Note: Some messages have been simplified; recompile with -Xdiags:verbose to get full output
1 error
Language: C++

#include <bits/stdc++.h>
using namespace std;
typedef long long LL;
int main(){
    cin.tie(0);
    ios::sync_with_stdio(false);
    int N, M;
    cin >> N >> M;
    vector<LL> a(N+1, 0);
    for (i=0;i<n;i++){
        cin >> a[i+1];
        a[i+1] += a[i];
    }
    for(i=0;i<n+1;i++) a[i] %= M;
    sort(a.begin(),a.end());
    LL now = 0, ct = 0;
    LL ans = 0;
    for(i=0;i<n+1;i++){
        if(i == N || now != a[i]){
            if(i == N && now == a[i]) ct++;
            now = a[i];
            ans += ct*(ct-1)/2;
            ct = 1;
        }else{
            ct++;
        }
    }
    cout << ans << endl;
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:10: error: 'i' was not declared in this scope
   10 |     for (i=0;i<n;i++){
      |          ^
a.cc:10:16: error: 'n' was not declared in this scope
   10 |     for (i=0;i<n;i++){
      |                ^
a.cc:14:9: error: 'i' was not declared in this scope
   14 |     for(i=0;i<n+1;i++) a[i] %= M;
      |         ^
a.cc:14:15: error: 'n' was not declared in this scope
   14 |     for(i=0;i<n+1;i++) a[i] %= M;
      |               ^
a.cc:18:9: error: 'i' was not declared in this scope
   18 |     for(i=0;i<n+1;i++){
      |         ^
a.cc:18:15: error: 'n' was not declared in this scope
   18 |     for(i=0;i<n+1;i++){
      |               ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main(){
    int N, M;
    cin >> N >> M;
    vector<long long> a(N+1, 0);
    for (i=0;i<n;i++){
        cin >> a[i+1];
        a[i+1] += a[i];
    }
    for (i=0;i<n+1;i++) a[i] %= M;
    sort(all(a));
    long long now = 0, ct = 0;
    long long ans = 0;
    for (i=0;i<n+1;i++){
        if(i == N || now != a[i]){
            if(i == N && now == a[i]) ct++;
            now = a[i];
            ans += ct*(ct-1)/2;
            ct = 1;
        }else{
            ct++;
        }
    }
    cout << ans << endl;
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:10: error: 'i' was not declared in this scope
    7 |     for (i=0;i<n;i++){
      |          ^
a.cc:7:16: error: 'n' was not declared in this scope
    7 |     for (i=0;i<n;i++){
      |                ^
a.cc:11:10: error: 'i' was not declared in this scope
   11 |     for (i=0;i<n+1;i++) a[i] %= M;
      |          ^
a.cc:11:16: error: 'n' was not declared in this scope
   11 |     for (i=0;i<n+1;i++) a[i] %= M;
      |                ^
a.cc:12:10: error: 'all' was not declared in this scope; did you mean 'std::filesystem::perms::all'?
   12 |     sort(all(a));
      |          ^~~
      |          std::filesystem::perms::all
In file included from /usr/include/c++/14/filesystem:51,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:200,
                 from a.cc:1:
/usr/include/c++/14/bits/fs_fwd.h:158:7: note: 'std::filesystem::perms::all' declared here
  158 |       all               =  0777,
      |       ^~~
a.cc:15:10: error: 'i' was not declared in this scope
   15 |     for (i=0;i<n+1;i++){
      |          ^
a.cc:15:16: error: 'n' was not declared in this scope
   15 |     for (i=0;i<n+1;i++){
      |                ^
Language: C++

#include <bits/stdc++.h>
using namesapce std;
int main()
{
int n,k;
int c=n % k;
if(c==0)
{
cout<<c;
return 0;
}
cout<<1;
return 0;
}

Compiler output:
a.cc:2:7: error: expected nested-name-specifier before 'namesapce'
    2 | using namesapce std;
      |       ^~~~~~~~~
a.cc: In function 'int main()':
a.cc:9:1: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    9 | cout<<c;
      | ^~~~
      | std::cout
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:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:12:1: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   12 | cout<<1;
      | ^~~~
      | std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
Language: C++

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

int main(){
  int N, K;
  cin >> N >> K;

  int res;
  if(N % K == 0){
    res = 0;
  }else if{
    res = 1;
  }
  cout << res << endl;
}


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

#include <bits/stdc++.h>
using namespace std;
int main(void){
  int N,K;
  cin>>N>>K;
  if(N%K==0){
    cout<<0;
  }
  else{
    cout<<!;
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:10:12: error: expected primary-expression before ';' token
   10 |     cout<<!;
      |            ^
Language: C++

#include <iostream>
#include <string>
using namespace std;


int main(){
    int N,K;
    cin >> N >> K;
    
    if(N%K==0){
        cout << 0;
    }else{
        cout << 1;
}



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

#include <iostream>
using namespace std;

intamin(void){
  int n,k;
  cin >> n >> k;
  cout << !!(n%k) << endl;
  return 0;
}

Compiler output:
a.cc:4:1: error: ISO C++ forbids declaration of 'intamin' with no type [-fpermissive]
    4 | intamin(void){
      | ^~~~~~~
Language: C++

#include<stdio.h>
int main (){
  int n,k;
  if(n%k==0) printf("0\n");
  else printf("1\n");
  return 0
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:11: error: expected ';' before '}' token
    6 |   return 0
      |           ^
      |           ;
    7 | }
      | ~
Language: C++

#include<bits/stdc++.h>
#define REP(i,a,b) for(int i=(a);i<(int)(b);++i)
#define rep(i,n) REP(i,0,n)
#define dump(x)  cout << #x << " = " << (x) << endl;
#define debug(x) cout << #x << " = " << (x) << " (L" << __LINE__ << ")" << " " << __FILE__ << endl;

using namespace std;
typedef long long ll;

int main() {
    int n, k;
    cin >> n >> k;
    if (n == 0)
        cout << 0 << endl;
    else (n < k)
        cout << 1 << endl;
    else
        cout << n % k << endl;
    return 0;
}



Compiler output:
a.cc: In function 'int main()':
a.cc:15:17: error: expected ';' before 'cout'
   15 |     else (n < k)
      |                 ^
      |                 ;
   16 |         cout << 1 << endl;
      |         ~~~~     
a.cc:17:5: error: 'else' without a previous 'if'
   17 |     else
      |     ^~~~
Language: C++

#include<stdio.h>
int main ( )
{
int  n,k ;
scanf (”%d%d ” , &n , &k ) ;
printf (”%d\n ” , n%k != 0 ) ;
}

Compiler output:
a.cc:5:8: error: extended character ” is not valid in an identifier
    5 | scanf (”%d%d ” , &n , &k ) ;
      |        ^
a.cc:5:14: error: extended character ” is not valid in an identifier
    5 | scanf (”%d%d ” , &n , &k ) ;
      |              ^
a.cc:6:9: error: extended character ” is not valid in an identifier
    6 | printf (”%d\n ” , n%k != 0 ) ;
      |         ^
a.cc:6:12: error: stray '\' in program
    6 | printf (”%d\n ” , n%k != 0 ) ;
      |            ^
a.cc:6:15: error: extended character ” is not valid in an identifier
    6 | printf (”%d\n ” , n%k != 0 ) ;
      |               ^
a.cc: In function 'int main()':
a.cc:5:8: error: '\U0000201d' was not declared in this scope
    5 | scanf (”%d%d ” , &n , &k ) ;
      |        ^
a.cc:5:10: error: 'd' was not declared in this scope
    5 | scanf (”%d%d ” , &n , &k ) ;
      |          ^
Language: C++

#i n cl u d e <s t d i o . h>
i n t main ( )
{
i n t  n,k ;
scanf (”%d%d ” , &n , &k ) ;
printf (”%d\n ” , n%k != 0 ) ;
}


Compiler output:
a.cc:1:2: error: invalid preprocessing directive #i; did you mean #if?
    1 | #i n cl u d e <s t d i o . h>
      |  ^
      |  if
a.cc:5:8: error: extended character ” is not valid in an identifier
    5 | scanf (”%d%d ” , &n , &k ) ;
      |        ^
a.cc:5:14: error: extended character ” is not valid in an identifier
    5 | scanf (”%d%d ” , &n , &k ) ;
      |              ^
a.cc:6:9: error: extended character ” is not valid in an identifier
    6 | printf (”%d\n ” , n%k != 0 ) ;
      |         ^
a.cc:6:12: error: stray '\' in program
    6 | printf (”%d\n ” , n%k != 0 ) ;
      |            ^
a.cc:6:15: error: extended character ” is not valid in an identifier
    6 | printf (”%d\n ” , n%k != 0 ) ;
      |               ^
a.cc:2:1: error: 'i' does not name a type
    2 | i n t main ( )
      | ^
Language: C++

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

int main() {
  if (N % K != 0) {
    cout << 1 << endl;
  }
  else {
    cout << 0 << endl;
  }
}


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

#include<bits/stdc++.h>
using namespace std;
int main()
{
	cin>>n>>k;
	if(n%k==0)cout<<0;else cout<<1;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:14: error: 'n' was not declared in this scope; did you mean 'yn'?
    5 |         cin>>n>>k;
      |              ^
      |              yn
a.cc:5:17: error: 'k' was not declared in this scope
    5 |         cin>>n>>k;
      |                 ^
Language: C++

#include<iostream.h>
using namespace std;
int main()
{
  int n,k;
  cin>>n>>k;
  if(n%k==0)
    cout<<0;
  else
    cout<<1;
  

  return 0;
}

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

#include <iostream>

int main() {
  int N, K;
  std::cin >> N >> K;

  int remain = 0;
  if ( N >= K ) {
    remain = N % K;
    std::cout << remain << std::endl;
  else {
    std::cout << remain << std::endl;
  }

  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:11:3: error: expected '}' before 'else'
   11 |   else {
      |   ^~~~
a.cc:8:17: note: to match this '{'
    8 |   if ( N >= K ) {
      |                 ^
Language: C++

#include <iostream>

int main() {
  int N, K;
  std::cin >> N >> K;

  int remain = 0;
  if ( N >= K ) {
    int remain = N % K;
    std::cout << remain << std::endl;
  else {
    std::cout << remain << std::endl;
  }

  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:11:3: error: expected '}' before 'else'
   11 |   else {
      |   ^~~~
a.cc:8:17: note: to match this '{'
    8 |   if ( N >= K ) {
      |                 ^
Language: C++

#include<bits/c++.h>

using namespace std;

int main(){
  int n,k;
  
  cin >> n >> k;
  
  cout << n % k << endl;
}

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

#include<stdio.h>
int main(){
int N,i,j,k,ans;
scanf("%d",&N);
for(i=0;i<25;i++){
  for(j=0;j<15;j++){
  k = i*4 + j*7)==0;
    if(N%k==0){
    ans++;
    }
  }
}
if(ans){
  printf("Yes");
}else{
  printf("No");
}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:16: error: expected ';' before ')' token
    7 |   k = i*4 + j*7)==0;
      |                ^
      |                ;
Language: C++

#include<stdio.h>
int main(){
int N,i,j,k,ans;
scanf("%d",&N);
for(i=0;i<25;i++){
  for(j=0;j<15;j++){
  k = i*4 + j*7)==0;
    if(N%k==00{
    ans++;
    }
  }
}
if(ans){
  printf("Yes");
}else{
  printf("No");
}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:16: error: expected ';' before ')' token
    7 |   k = i*4 + j*7)==0;
      |                ^
      |                ;
a.cc:8:15: error: expected ')' before '{' token
    8 |     if(N%k==00{
      |       ~       ^
      |               )
a.cc:11:3: error: expected primary-expression before '}' token
   11 |   }
      |   ^
Language: C++

#include<stdio.h>
int main(){
int N,K,dif;
scanf("%d%d",&N,&K);
dif = N%K;

if(dif){printf("%d",1)
}else{
  printf("%d",0)
}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:23: error: expected ';' before '}' token
    7 | if(dif){printf("%d",1)
      |                       ^
      |                       ;
    8 | }else{
      | ~                      
a.cc:9:17: error: expected ';' before '}' token
    9 |   printf("%d",0)
      |                 ^
      |                 ;
   10 | }
      | ~
Language: C++

#include <stdio.h>

int main()
{

int N, K;

scanf("%d", &N);
scanf("%d", &K);

int res = N%K;

if(res==0) printf("0\n");
else printf("1\n")

return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:14:19: error: expected ';' before 'return'
   14 | else printf("1\n")
      |                   ^
      |                   ;
   15 | 
   16 | return 0;
      | ~~~~~~
Language: C++

int main()
{

int N, K;

scanf("%d", &N);
scanf("%d", &K);

int res = N%K;

if(res==0) printf("0");
else printf("1");

return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:1: error: 'scanf' was not declared in this scope
    6 | scanf("%d", &N);
      | ^~~~~
a.cc:11:12: error: 'printf' was not declared in this scope
   11 | if(res==0) printf("0");
      |            ^~~~~~
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:12:6: error: 'printf' was not declared in this scope
   12 | else printf("1");
      |      ^~~~~~
a.cc:12:6: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
Language: C++

#include "bits/stdc++.h"
#define rep(i,n) for(int i = 0;i < n;i++)
#define REP(i,n,k) for(int i = n;i < k;i++)
#define P(p) cout << (p) << endl;
#define sP(p) cout << setprecision(15) << fixed << p << endl;
#define vi vector<int>
#define printv(v) for(int i = 0;i < v.size();i++)P(v[i]);
#define printt(a,b) cout << a << " " << b << endl; 
#define mp(a,b) make_pair(a,b)
#define pb(a) push_back(a)

using namespace std;
typedef long long ll;
typedef unsigned long long ull;
int dx[] = { 1, -1 , 0 , 0};
int dy[] = { 0,  0,  1, -1};
int MOD = 1e9 + 7;

void solve() {
    int n,k;
    cin >> n >> k;
    if(n % k == 0){
        P(0);
    }else{
        P(1);
    }
}

int main() {
    solve();
    return 0;
}
#include "bits/stdc++.h"
#define rep(i,n) for(int i = 0;i < n;i++)
#define REP(i,n,k) for(int i = n;i < k;i++)
#define P(p) cout << (p) << endl;
#define sP(p) cout << setprecision(15) << fixed << p << endl;
#define vi vector<int>
#define printv(v) for(int i = 0;i < v.size();i++)P(v[i]);
#define printt(a,b) cout << a << " " << b << endl; 
#define mp(a,b) make_pair(a,b)
#define pb(a) push_back(a)

using namespace std;
typedef long long ll;
typedef unsigned long long ull;
int dx[] = { 1, -1 , 0 , 0};
int dy[] = { 0,  0,  1, -1};
int MOD = 1e9 + 7;

void solve() {
    int n,k;
    cin >> n >> k;
    if(n % k == 0){
        P(0);
    }else{
        P(1);
    }
}

int main() {
    solve();
    return 0;
}


Compiler output:
a.cc:47:5: error: redefinition of 'int dx []'
   47 | int dx[] = { 1, -1 , 0 , 0};
      |     ^~
a.cc:15:5: note: 'int dx [4]' previously defined here
   15 | int dx[] = { 1, -1 , 0 , 0};
      |     ^~
a.cc:48:5: error: redefinition of 'int dy []'
   48 | int dy[] = { 0,  0,  1, -1};
      |     ^~
a.cc:16:5: note: 'int dy [4]' previously defined here
   16 | int dy[] = { 0,  0,  1, -1};
      |     ^~
a.cc:49:5: error: redefinition of 'int MOD'
   49 | int MOD = 1e9 + 7;
      |     ^~~
a.cc:17:5: note: 'int MOD' previously defined here
   17 | int MOD = 1e9 + 7;
      |     ^~~
a.cc:51:6: error: redefinition of 'void solve()'
   51 | void solve() {
      |      ^~~~~
a.cc:19:6: note: 'void solve()' previously defined here
   19 | void solve() {
      |      ^~~~~
a.cc:61:5: error: redefinition of 'int main()'
   61 | int main() {
      |     ^~~~
a.cc:29:5: note: 'int main()' previously defined here
   29 | int main() {
      |     ^~~~
Language: C++

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

int main(void) {
  int n, k;

  if(n%k=0) {
    cout << 1 << endl;
  } else {
    cout << 0 << endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:7: error: lvalue required as left operand of assignment
    7 |   if(n%k=0) {
      |      ~^~
Language: C++

#include <iostream>
using namespace std;

int
main()
{
int N, K;

cin >> N;
cin >> K;

cout << N % K != 0 << "\n";

return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:20: error: invalid operands of types 'int' and 'const char [2]' to binary 'operator<<'
   12 | cout << N % K != 0 << "\n";
      |                  ~ ^~ ~~~~
      |                  |    |
      |                  int  const char [2]
Language: C++

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace abc105_a
{
    class Program
    {
        static void Main(string[] args)
        {
            string[] nums = Console.ReadLine().Split(' ');
            int n = int.Parse(nums[0]);
            int k = int.Parse(nums[1]);

            if(n % k == 0)
            {
                Console.WriteLine(0);
            }
            else
            {
                Console.WriteLine(1);
            }
        }
    }
}

Compiler output:
a.cc:1:7: error: expected nested-name-specifier before 'System'
    1 | using System;
      |       ^~~~~~
a.cc:2:7: error: expected nested-name-specifier before 'System'
    2 | using System.Collections.Generic;
      |       ^~~~~~
a.cc:3:7: error: expected nested-name-specifier before 'System'
    3 | using System.Linq;
      |       ^~~~~~
a.cc:4:7: error: expected nested-name-specifier before 'System'
    4 | using System.Text;
      |       ^~~~~~
a.cc:5:7: error: expected nested-name-specifier before 'System'
    5 | using System.Threading.Tasks;
      |       ^~~~~~
a.cc:11:26: error: 'string' has not been declared
   11 |         static void Main(string[] args)
      |                          ^~~~~~
a.cc:11:35: error: expected ',' or '...' before 'args'
   11 |         static void Main(string[] args)
      |                                   ^~~~
a.cc:26:6: error: expected ';' after class definition
   26 |     }
      |      ^
      |      ;
a.cc: In static member function 'static void abc105_a::Program::Main(int*)':
a.cc:13:13: error: 'string' was not declared in this scope
   13 |             string[] nums = Console.ReadLine().Split(' ');
      |             ^~~~~~
a.cc:13:20: error: expected primary-expression before ']' token
   13 |             string[] nums = Console.ReadLine().Split(' ');
      |                    ^
a.cc:14:21: error: expected primary-expression before 'int'
   14 |             int n = int.Parse(nums[0]);
      |                     ^~~
a.cc:15:21: error: expected primary-expression before 'int'
   15 |             int k = int.Parse(nums[1]);
      |                     ^~~
a.cc:19:17: error: 'Console' was not declared in this scope
   19 |                 Console.WriteLine(0);
      |                 ^~~~~~~
a.cc:23:17: error: 'Console' was not declared in this scope
   23 |                 Console.WriteLine(1);
      |                 ^~~~~~~
Language: C++

#include <iostream>
using namespace std;

int main() {
	int N;
	cin >> N;
	int CMAX = 100 / 4;
	int DMAX = 100 / 7;
	for (int i = 0; i <= CMAX; i++) {
		for (int j = 0; j <= DMAX; j++) {
			if (i * 4 + j * 4 == N) {
				cerr << "Yes" << endl;
				return;
			}
		}
	}
	cerr << "No" << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:33: error: return-statement with no value, in function returning 'int' [-fpermissive]
   13 |                                 return;
      |                                 ^~~~~~
Language: C

#include <stdio.h>

int main(){
 int n,m;
 scanf(“%d %d”,&n,&m);
 printf(“%d”,n%m);
return 0;
}


Compiler output:
main.c: In function 'main':
main.c:5:8: error: stray '\342' in program
    5 |  scanf(<U+201C>%d %d<U+201D>,&n,&m);
      |        ^~~~~~~~
main.c:5:9: error: expected expression before '%' token
    5 |  scanf(“%d %d”,&n,&m);
      |         ^
main.c:5:14: error: stray '\342' in program
    5 |  scanf(<U+201C>%d %d<U+201D>,&n,&m);
      |                     ^~~~~~~~
main.c:6:9: error: stray '\342' in program
    6 |  printf(<U+201C>%d<U+201D>,n%m);
      |         ^~~~~~~~
main.c:6:10: error: expected expression before '%' token
    6 |  printf(“%d”,n%m);
      |          ^
main.c:6:12: error: stray '\342' in program
    6 |  printf(<U+201C>%d<U+201D>,n%m);
      |                   ^~~~~~~~
Language: C++

#include <studio.h>

int main(){
 int n,m;
 scanf(“%d %d”,&n,&m);
 printf(“%d”,n%m);
return 0;
}

Compiler output:
a.cc:1:10: fatal error: studio.h: No such file or directory
    1 | #include <studio.h>
      |          ^~~~~~~~~~
compilation terminated.
Language: C++

#include <iostream>
using namespace std;
int main() {
int N;
cin >> N;
int answer = 0;
for (int C = 1; C <= N; C += 2) {
    int num_of_divisors = 0;
    for (int X = 1; X <= C; ++X) {
        if(C % X == 0) {
            ++num_of_divisors;
        }
    }
if (num_of_divisors == 8) {
    ++answer;
    }
}
cout << answer << "\n"
 resturn 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:18:23: error: expected ';' before 'resturn'
   18 | cout << answer << "\n"
      |                       ^
      |                       ;
   19 |  resturn 0;
      |  ~~~~~~~
Language: C++

#include <iostream>
using namespace std;
int main() {
int N;
cin >> N;
int answer = 0;
for (int C = 1; C <= N; C += 2) {
    int num_of_divisors = 0;
    for (int X = 1; X <= C; ++X) {
        if(C % X == 0) {
            ++num_of_divisors;
        }
    }
if (num_of_divisors == 8) {
    ++answer;
    }
}
cout << answer << "\n"
resturn 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:18:23: error: expected ';' before 'resturn'
   18 | cout << answer << "\n"
      |                       ^
      |                       ;
   19 | resturn 0;
      | ~~~~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main () {
  int N, K;
  K != 0
  cin >> N, K;
  if ( N % K == 0)
  {
    cout << 0 << endl;
  }
  else {
    cout << 1 << endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:9: error: expected ';' before 'cin'
    6 |   K != 0
      |         ^
      |         ;
    7 |   cin >> N, K;
      |   ~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main () {
  int N, K;
  N != 0;
  cin >> N, K;
  if ( N % K = 0)
  {
    cout << 0 << endl;
  }
  else {
    cout << 1 << endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:10: error: lvalue required as left operand of assignment
    8 |   if ( N % K = 0)
      |        ~~^~~
Language: C++

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

int main () {
  int N, K;
  N != 0;
  cin >> N, K;
  if ( N % K = 0 )
  {
    cout << 0 << endl;
  }
  else {
    cout << 1 << endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:10: error: lvalue required as left operand of assignment
    8 |   if ( N % K = 0 )
      |        ~~^~~
Language: C++

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

int main () {
  int N, K;
  cin >> N, K;
  if ( N % K = 0 )
  {
    cout << 0 << endl;
  }
  else {
    cout << 1 << endl;
  }
}
  
 


Compiler output:
a.cc: In function 'int main()':
a.cc:7:10: error: lvalue required as left operand of assignment
    7 |   if ( N % K = 0 )
      |        ~~^~~
Language: C++

#include <iostream>
using namespace std;

int main(){
  int n, k; cin >> n >> k;
  vector <int> cnt(k);
  for (int i = 0; i < n; i++){
    cnt[i%k] += 1;
  }
  sort(cnt.begin(), cnt.end());
  cout << cnt.back() - cnt.front() << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:3: error: 'vector' was not declared in this scope
    6 |   vector <int> cnt(k);
      |   ^~~~~~
a.cc:2:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
    1 | #include <iostream>
  +++ |+#include <vector>
    2 | using namespace std;
a.cc:6:11: error: expected primary-expression before 'int'
    6 |   vector <int> cnt(k);
      |           ^~~
a.cc:8:5: error: 'cnt' was not declared in this scope; did you mean 'int'?
    8 |     cnt[i%k] += 1;
      |     ^~~
      |     int
a.cc:10:8: error: 'cnt' was not declared in this scope; did you mean 'int'?
   10 |   sort(cnt.begin(), cnt.end());
      |        ^~~
      |        int
a.cc:10:3: error: 'sort' was not declared in this scope; did you mean 'short'?
   10 |   sort(cnt.begin(), cnt.end());
      |   ^~~~
      |   short
Language: C++

#include<iostream>

int main(){
  int n,k;
  std::cin >> n >> k;
  if(n%k==0) cout << 0 << endl;
  else cout << 1 << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:14: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    6 |   if(n%k==0) cout << 0 << endl;
      |              ^~~~
      |              std::cout
In file included from a.cc:1:
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:6:27: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    6 |   if(n%k==0) cout << 0 << endl;
      |                           ^~~~
      |                           std::endl
In file included from /usr/include/c++/14/iostream:41:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
a.cc:7:8: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    7 |   else cout << 1 << 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:21: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    7 |   else cout << 1 << endl;
      |                     ^~~~
      |                     std::endl
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: C++

#include <iostream>
using namespace std;

int main(){
  int n,k;
  cin >> n >> k;
  
  cout << (n%k==0) ? 0 : 1 endl;
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:27: error: expected ';' before 'endl'
    8 |   cout << (n%k==0) ? 0 : 1 endl;
      |                           ^~~~~
      |                           ;
Language: C++

#include <iostream>
using namespace std;

int main(){
  int n,k;
  cin >> n >> k;
  
  cout << (n%k==0) ? 0 : 1; endl;
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:33: error: statement cannot resolve address of overloaded function
    8 |   cout << (n%k==0) ? 0 : 1; endl;
      |                                 ^
Language: C

#include<stdio.h>

int main(){
    int N,K;

    scanf("%d",&N);
    scanf("%d", &K);
    if(N%k != 0)
        printf("1\n");
    
    else
    {
        printf("0\n");
    }
    
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:8:10: error: 'k' undeclared (first use in this function)
    8 |     if(N%k != 0)
      |          ^
main.c:8:10: note: each undeclared identifier is reported only once for each function it appears in
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{
	int N,K,c;
	cin>>N>>K;
{
        if(N<K)
        c=1;
        else
        c=N%K;
 }                   
        c=fabs(c)
	cout>>c>>endl;
	return 0;
 } 

Compiler output:
a.cc: In function 'int main()':
a.cc:13:18: error: expected ';' before 'cout'
   13 |         c=fabs(c)
      |                  ^
      |                  ;
   14 |         cout>>c>>endl;
      |         ~~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{
	int N,K,c;
	cin>>N>>K;
	if(N>=K)    
	c=N%K;
	c=fabs(c);
	else 
	c==1;
	 
	cout<<c<<endl;
	return 0;
 } 

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

#include<bits/stdc++.h>
using namespace std;
int main()
{
	int N,K,c;
	cin>>N>>K;
	if(N>=K)    
	c=N%K;
	c=fabs(c);
	else 
	c=1;
	 
	cout<<c<<endl;
	return 0;
 } 

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

#include<bits/stdc++.h>
using namespace std;
int main()
{
	int N,K,c;
	cin>>N>>K;
	c=N%K;
        c=fabs(c)
	cout<<c<<endl;
	return 0;
 } 

Compiler output:
a.cc: In function 'int main()':
a.cc:8:18: error: expected ';' before 'cout'
    8 |         c=fabs(c)
      |                  ^
      |                  ;
    9 |         cout<<c<<endl;
      |         ~~~~
Language: C++

#include <iostream>
#include <algorithm>

using namespace std;

int main(){
    int n, k;
    cin >> n >> k;
    if(n % k == 0){
        cout << 0 << endl;
        return 0;
    }
    cout << abs((n /k) -1) << endl;
    return 0;

Compiler output:
a.cc: In function 'int main()':
a.cc:14:14: error: expected '}' at end of input
   14 |     return 0;
      |              ^
a.cc:6:11: note: to match this '{'
    6 | int main(){
      |           ^
Language: C

#include <stdio.h>

int main(){

int N,K,answer;
scanf("%d %d",&N,&K);

if(N % f != 0){
answer = 1;
}

if(N % f == 0){
answer = 0;
}

printf("%d",answer);

return 0;
}

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

#include <stdio.h>

int main(){

int N,K,answer;
scanf("%d %d",&N,&K);

if(N % f != 0)
answer = 1;

if(N % f == 0)
answer = 0;

printf("%d",answer);

return 0;
}

Compiler output:
main.c: In function 'main':
main.c:8:8: error: 'f' undeclared (first use in this function)
    8 | if(N % f != 0)
      |        ^
main.c:8:8: note: each undeclared identifier is reported only once for each function it appears in
Language: C++

#include <iostream>

using namespace std;

int main(){
  int n, k;
  cin >> n >> k;
  cout << n % k == 0 << endl;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:22: error: invalid operands of types 'int' and '<unresolved overloaded function type>' to binary 'operator<<'
    8 |   cout << n % k == 0 << endl;
      |                    ~~^~~~~~~
Language: Java

import java.util.Scanner;

public class A105_B {

	static void show(boolean b){
		if(b) System.out.println("Yes");
		else System.out.println("No");
	}

	public static void main(String[] args) throws Exception {
        Scanner sc = new Scanner(System.in);

        boolean result = false;

        int n = sc.nextInt();

        if(n % 4 == 0 || n % 7 == 0){
        	result = true;
        }
        else{
        	int x = 1;
        	while(4*x < n){
        		if((n - 4*x) % 7 == 0){
        			result = true;
        			break;
        		}
        		x++;
        	}
        }

        show(result);
	}
}

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

fn main() {
    let mut s = String::new();
    std::io::stdin().read_line(&mut s).unwrap();
    let input:Vec<_> = s.split_whitespace().map(|x| x.parse::<i32>().unwrap()).collect();

    if input[0] % input[1] == 0 {
        println!("0");
    }else {
        println!("1");
    }
}


Compiler output:
a.cc:1:1: error: 'fn' does not name a type
    1 | fn main() {
      | ^~
Language: C++

#include <iostream>

int main() {
    int n = 0;
    int k = 0;
    std::cin >> n >> k;
    if (n % k == 0) {
        std::cout << "0" << std::endl;
    } else {
        std::cout << "1" << std:endl;
    }
    std::cout << "Hello, World!" << std::endl;
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:32: error: found ':' in nested-name-specifier, expected '::'
   10 |         std::cout << "1" << std:endl;
      |                                ^
      |                                ::
Language: C++

using namespace std;

int n, k;

int main(){
    cin >> n >> k;
    if(n % k == 0){
        cout << 0 << endl;
    } else {
        cout << 1 << endl;
    }
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:5: error: 'cin' was not declared in this scope
    6 |     cin >> n >> 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:8:9: error: 'cout' was not declared in this scope
    8 |         cout << 0 << endl;
      |         ^~~~
a.cc:8:9: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:8:22: error: 'endl' was not declared in this scope
    8 |         cout << 0 << 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:10:9: error: 'cout' was not declared in this scope
   10 |         cout << 1 << endl;
      |         ^~~~
a.cc:10:9: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:10:22: error: 'endl' was not declared in this scope
   10 |         cout << 1 << endl;
      |                      ^~~~
a.cc:10: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;

void solve1() {
	int N;
	cin >> N;

	//calculate
	string ans = "No";
	if (N >= 28) {
		ans = "Yes";
	} else {
		if (N % 4 == 0) {
			ans = "Yes";
			break;
		}
		for (int i = 0; i < 3; ++i) {
			N -= 7;
			if (N < 0) {
				ans = "No";
				break;
			} else if (N % 4 == 0) {
				ans = "Yes";
				break;
			}
		}
	}

	//print
	cout << ans << '\n';
}


int main() {
	solve1();
	return 0;
}

Compiler output:
a.cc: In function 'void solve1()':
a.cc:16:25: error: break statement not within loop or switch
   16 |                         break;
      |                         ^~~~~
Language: C++

void solve1() {
	int N;
	cin >> N;

	//calculate
	string ans = "No";
	if (N >= 28) {
		ans = "Yes";
	} else {
		for (int i = 0; i < 3; ++i) {
			N -= 7;
			if (N < 0) {
				ans = "No";
				break;
			} else if (N % 4 == 0) {
				ans = "Yes";
				break;
			}
		}
	}

	//print
	cout << ans << '\n';
}
int main() {
	solve1();
	return 0;
}

Compiler output:
a.cc: In function 'void solve1()':
a.cc:3:9: error: 'cin' was not declared in this scope
    3 |         cin >> N;
      |         ^~~
a.cc:6:9: error: 'string' was not declared in this scope
    6 |         string ans = "No";
      |         ^~~~~~
a.cc:8:17: error: 'ans' was not declared in this scope
    8 |                 ans = "Yes";
      |                 ^~~
a.cc:13:33: error: 'ans' was not declared in this scope
   13 |                                 ans = "No";
      |                                 ^~~
a.cc:16:33: error: 'ans' was not declared in this scope
   16 |                                 ans = "Yes";
      |                                 ^~~
a.cc:23:9: error: 'cout' was not declared in this scope
   23 |         cout << ans << '\n';
      |         ^~~~
a.cc:23:17: error: 'ans' was not declared in this scope
   23 |         cout << ans << '\n';
      |                 ^~~
Language: Java

class Main
{
		public static void main(String[] args) throws Exception {
		/** TODO
		 * Goal:せんべいを最も多く貰った人と最も少なく貰った人のせんべいの枚数の差の最小値
		 *
		 * 最大値と最小値の余りを求めるプログラミング
		**/

		// Your code here!
        Scanner sc = new Scanner(System.in);
        
        //Number of Atcoder crackers
        int n = sc.nextInt();
        
        //Number of mans
        int k = sc.nextInt();

        int answer = n % k;

        System.out.println( answer );
	}
}

Compiler output:
Main.java:11: error: cannot find symbol
        Scanner sc = new Scanner(System.in);
        ^
  symbol:   class Scanner
  location: class Main
Main.java:11: error: cannot find symbol
        Scanner sc = new Scanner(System.in);
                         ^
  symbol:   class Scanner
  location: class Main
2 errors
Language: C

#include<stdio.h>
main()
{
	int r>=0;
	scanf("%d", &r);
	if(r<1200){
		printf("ABC");
	}if(r<2800){
		printf("ARC");
	}if(r<=4208){
		printf("AGC");
	}
}

Compiler output:
main.c:2:1: error: return type defaults to 'int' [-Wimplicit-int]
    2 | main()
      | ^~~~
main.c: In function 'main':
main.c:4:14: error: expected '=', ',', ';', 'asm' or '__attribute__' before '>=' token
    4 |         int r>=0;
      |              ^~
main.c:4:14: error: expected expression before '>=' token
main.c:5:22: error: 'r' undeclared (first use in this function)
    5 |         scanf("%d", &r);
      |                      ^
main.c:5:22: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include<stdio.h>
main()
{
	int r>=0;
	scanf("%d", &r);
	if(r<1200){
		printf("ABC");
	}else if(r<2800){
		printf("ARC");
	}else if(r<=4208){
		printf("AGC");
	}
}

Compiler output:
main.c:2:1: error: return type defaults to 'int' [-Wimplicit-int]
    2 | main()
      | ^~~~
main.c: In function 'main':
main.c:4:14: error: expected '=', ',', ';', 'asm' or '__attribute__' before '>=' token
    4 |         int r>=0;
      |              ^~
main.c:4:14: error: expected expression before '>=' token
main.c:5:22: error: 'r' undeclared (first use in this function)
    5 |         scanf("%d", &r);
      |                      ^
main.c:5:22: note: each undeclared identifier is reported only once for each function it appears in
Language: C++

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

int main(){
  int a,b;
  cin >> a >> b;
  if(a%b==0){
    cout << 0 << endl;
  }else{
    cout << 1 << endl;
    
}
  

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

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

int main() {
  int N, K;
  cin >> N >> K;

  if (N % K >== 1) {
    cout << 1 << endl;
  }

  else {
    cout << 0 << endl;
  }

}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:15: error: expected primary-expression before '=' token
    8 |   if (N % K >== 1) {
      |               ^
Language: Java


import java.util.*;

public class Main{  
    public static void main(String[] args){

        Scanner sc1 =new Scanner(System.in);
        int N=nextInt();
        int K=nextInt();

        if(N%K==0){
            System.out.println(0);
        }else{
            System.out.println(1);
        }
        
    }
}

Compiler output:
Main.java:8: error: cannot find symbol
        int N=nextInt();
              ^
  symbol:   method nextInt()
  location: class Main
Main.java:9: error: cannot find symbol
        int K=nextInt();
              ^
  symbol:   method nextInt()
  location: class Main
2 errors
Language: Java


import java.util.*;

public class Cracker{  
    public static void main(String[] args){

        Scanner sc1 =new Scanner(System.in);
        int N=nextInt();
        int K=nextInt();

        if(N%K==0){
            System.out.println(0);
        }else{
            System.out.println(1);
        }
        
    }
}

Compiler output:
Main.java:4: error: class Cracker is public, should be declared in a file named Cracker.java
public class Cracker{  
       ^
Main.java:8: error: cannot find symbol
        int N=nextInt();
              ^
  symbol:   method nextInt()
  location: class Cracker
Main.java:9: error: cannot find symbol
        int K=nextInt();
              ^
  symbol:   method nextInt()
  location: class Cracker
3 errors
Language: C

#include <stdio.h>

int Main(void){
 int N=0;
 int K=0;
 scanf("%d",&N);
 scanf("%d",&K);

 if(N%K==0) printf("0");
 else printf("1");
 
 return 0;
}

Compiler output:
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/14/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x17): undefined reference to `main'
collect2: error: ld returned 1 exit status
Language: C

#include <stdio.h>

int Main(void){
 int N=0,
      K=0;
 scanf("%d",&N);
 scanf("%d",&K);

 if(N%K==0) printf("0");
 else printf("1");
 
 return 0;
}

Compiler output:
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/14/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x17): undefined reference to `main'
collect2: error: ld returned 1 exit status
Language: C

#include <stdio.h>

int Main(void){
 int A=0,
      B=0;
 scanf("%d",&A);
 scanf("%d",&B);

 if(A%B==0) printf("0");
 else printf("1");
 
 return 0;
}

Compiler output:
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/14/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x17): undefined reference to `main'
collect2: error: ld returned 1 exit status
Language: C

#include <stdio.h>

int Main(void){
 int A=0,
      B=0;
 A=scanf("%d");
 B=scanf("%d");
 if(A%B==0) printf("0");
 else printf("1");
 
 return 0;
}

Compiler output:
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/14/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x17): undefined reference to `main'
collect2: error: ld returned 1 exit status
Language: C

#include <stdio.h>

int Main(void){
 int A=0,
      B=0;
 if(scanf("%d",&A));
 if(scanf("%d",&B));
 
 if(A%B==0) printf("0");
 else printf("1");
 
 return 0;
}

Compiler output:
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/14/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x17): undefined reference to `main'
collect2: error: ld returned 1 exit status
Language: C

#include <stdio.h>

int Main(void){
 int A=0,
      B=0;
 scanf("%d",&A);
 scanf("%d",&B);
 
 if(A%B==0) printf("0");
 else printf("1");
 
 return 0;
}

Compiler output:
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/14/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x17): undefined reference to `main'
collect2: error: ld returned 1 exit status
Language: C

#include <stdio.h>

int Main(void){
 int A,B;
 scanf("%d",&A);
 scanf("%d",&B);
 
 if(A%B==0) printf("0");
 else printf("1");
 
 return 0;
}

Compiler output:
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/14/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x17): undefined reference to `main'
collect2: error: ld returned 1 exit status
Language: C

#include <stdio.h>

int Main(void){
 int A,B;
 scanf("%d",&A)
 scanf("%d",&B);
 
 if(A%B==0) printf("0");
 else printf("1");
 
 return 0;
}

Compiler output:
main.c: In function 'Main':
main.c:5:16: error: expected ';' before 'scanf'
    5 |  scanf("%d",&A)
      |                ^
      |                ;
    6 |  scanf("%d",&B);
      |  ~~~~~
Language: C

#include <stdio.h>

int Main(void){
 int A,B;
 scanf("%d %d",&A,&B);
 
 if(A%B==0) printf("0");
 else printf("1");
 
 return 0;
}

Compiler output:
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/14/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x17): undefined reference to `main'
collect2: error: ld returned 1 exit status