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

        #include<iostream>
        using namespace std;
        int main(){
          char a[200000]={};
          char b[200000]={};
          cin>>b;
          char d='';
          int d=0;
          
          for(int d=0; d<=200000; d++){
            cin>>a[d];
          }
          for(int e=0; e<=200000; e++){
            cin>>b[e];
          }
          for(int f=0; f<=200000; f++){
            a[f]=b[f]
            if(a[f]!=b[f]){
              d++
            }
           }
          cout<<d;
        }
     
    #include<iostream>
    using namespace std;
    int main(){
      char a[200000]={};
      char b[200000]={};
      cin>>b;
      char d='';
      int d=0;
      
      for(int d=0; d<=200000; d++){
        cin>>a[d];
      }
      for(int e=0; e<=200000; e++){
        cin>>b[e];
      }
      for(int f=0; f<=200000; f++){
        a[f]=b[f]
        if(a[f]!=b[f]){
          d++
        }
       }
      cout<<d;
      return 0;
    }

Compiler output:
a.cc:7:18: error: empty character constant
    7 |           char d='';
      |                  ^~
a.cc:31:14: error: empty character constant
   31 |       char d='';
      |              ^~
a.cc: In function 'int main()':
a.cc:8:15: error: conflicting declaration 'int d'
    8 |           int d=0;
      |               ^
a.cc:7:16: note: previous declaration as 'char d'
    7 |           char d='';
      |                ^
a.cc:17:22: error: expected ';' before 'if'
   17 |             a[f]=b[f]
      |                      ^
      |                      ;
   18 |             if(a[f]!=b[f]){
      |             ~~        
a.cc: At global scope:
a.cc:27:9: error: redefinition of 'int main()'
   27 |     int main(){
      |         ^~~~
a.cc:3:13: note: 'int main()' previously defined here
    3 |         int main(){
      |             ^~~~
a.cc: In function 'int main()':
a.cc:32:11: error: conflicting declaration 'int d'
   32 |       int d=0;
      |           ^
a.cc:31:12: note: previous declaration as 'char d'
   31 |       char d='';
      |            ^
a.cc:41:18: error: expected ';' before 'if'
   41 |         a[f]=b[f]
      |                  ^
      |                  ;
   42 |         if(a[f]!=b[f]){
      |         ~~
Language: C

#include <stdio.h>

int main(void){
  char str1[100],str2[100];
  int i,cnt;
  scanf("%s",str1);
  scanf("%s",str2);
 
  for(i=0;int<100;i++){
    if(str1[i] != str2[i]){
      cnt++;
    }
  }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:9:11: error: expected expression before 'int'
    9 |   for(i=0;int<100;i++){
      |           ^~~
Language: C++

#include <bits/stdc++.h>
typedef long long ll;
using namespace std;
int main()
{
	string s,t;
	cin>>s>>t;
	ll ans=0;
	for(ll i=0;i<min(s.size(),t.size());i++)
	{
		if(s[i]!=t[i])
		{
			ans++;
		}
	}
	ans+=abs(s.size()-t.size());
	cout<<ans<<endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:16:17: error: call of overloaded 'abs(std::__cxx11::basic_string<char>::size_type)' is ambiguous
   16 |         ans+=abs(s.size()-t.size());
      |              ~~~^~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/14/cstdlib:79,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:42,
                 from a.cc:1:
/usr/include/stdlib.h:980:12: note: candidate: 'int abs(int)'
  980 | extern int abs (int __x) __THROW __attribute__ ((__const__)) __wur;
      |            ^~~
In file included from /usr/include/c++/14/cstdlib:81:
/usr/include/c++/14/bits/std_abs.h:137:3: note: candidate: 'constexpr __float128 std::abs(__float128)'
  137 |   abs(__float128 __x)
      |   ^~~
/usr/include/c++/14/bits/std_abs.h:85:3: note: candidate: 'constexpr __int128 std::abs(__int128)'
   85 |   abs(__GLIBCXX_TYPE_INT_N_0 __x) { return __x >= 0 ? __x : -__x; }
      |   ^~~
/usr/include/c++/14/bits/std_abs.h:79:3: note: candidate: 'constexpr long double std::abs(long double)'
   79 |   abs(long double __x)
      |   ^~~
/usr/include/c++/14/bits/std_abs.h:75:3: note: candidate: 'constexpr float std::abs(float)'
   75 |   abs(float __x)
      |   ^~~
/usr/include/c++/14/bits/std_abs.h:71:3: note: candidate: 'constexpr double std::abs(double)'
   71 |   abs(double __x)
      |   ^~~
/usr/include/c++/14/bits/std_abs.h:61:3: note: candidate: 'long long int std::abs(long long int)'
   61 |   abs(long long __x) { return __builtin_llabs (__x); }
      |   ^~~
/usr/include/c++/14/bits/std_abs.h:56:3: note: candidate: 'long int std::abs(long int)'
   56 |   abs(long __i) { return __builtin_labs(__i); }
      |   ^~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
string s, t;
int ans;
int main()
{
  cin>> s>> t;
  for(int i=0; i<s.length(); i++){
   	  if(s[i]!=t[i]) ans++;
  }
  cout<< ans;
  return;
}

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


/***

    Muhammad Imdad-Ul-Haque Rakib(Attari)
    CSE'19
    Chittagong,Bangladesh

***/

#include<bits/stdc++.h>

/**Definitions**/

#define   ld             long double
#define   ll             long long
#define   boost_         ios_base::sync_with_stdio(false);cin.tie(0);cout.tie(0);
#define   pb             push_back
#define   ppb            pop_back
#define   ull            unsigned long long
#define   over           return 0
#define   scan(i,n,a)    for(i=0;i<n;i++) cin>>a[i]
#define   MP             make_pair
#define   spc            " "

using namespace std;

/** Predefined Functions **/

int gcd(int x,int y){
    if(x==0) return y;
    else return gcd(y%x,x);
}
bool sortbysec(const pair<int,int>&a, const pair<int,int>&b){ return (a.second<b.second); }
bool sortbysecinrev(const pair<int,int>&a, const pair<int,int>&b){ return (a.second>b.second); }
bool sortbysize(string &s1,string &s2){ return s1.size() < s2.size(); }
bool sortinrev(const pair<int,int> &a, const pair<int,int> &b){ return (a.first > b.first); }


int main(){

    boost_;

    string s,t;
    cin>>s>>t;
    int cnt=0;
    
    for(i=0;i<s.size();++i){
        if(s[i]!=t[i]) ++cnt;
    }
    
    cout<<cnt<<endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:47:9: error: 'i' was not declared in this scope
   47 |     for(i=0;i<s.size();++i){
      |         ^
Language: C++

#include<bits\stdc++.h>
using namespace std;
int main()
{
     int i,j,c=0;
     string s,t;
     cin>>s>>t;
     for(i=0,j=0;i<s.size();i++,j++){
          if(s[i]==t[j])
               c++;
     }
     cout<<c<<endl;

     return 0;
}


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

#include<iostream>
#include<stdio.h>
#include<string.h>
using namespace std;
int main(void){
    char a[10000];
    char b[10000];
    int i, j, count=0;
    cin >> a;
    cin >> b;
    for(i=0; i<strlen(a); i++){
        if(a[i] != b[i]){
            ++count;
        }
    }
    cout << count << endl;
    return 0;
}

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

#include<bits/stdc++.h> 
using namespace std; 
  
// Function to find minimum number of operations required to transform 
// A to B. 
int minOps(string& A, string& B) 
{ 
    int m = A.length(), n = B.length(); 
  
     // This parts checks whether conversion is 
     // possible or not 
    if (n != m) 
       return -1; 
    int count[256]; 
    memset(count, 0, sizeof(count)); 
    for (int i=0; i<n; i++)   // count characters in A 
       count[B[i]]++; 
    for (int i=0; i<n; i++)   // subtract count for 
       count[A[i]]--;         // every character in B 
    for (int i=0; i<256; i++)   // Check if all counts become 0 
      if (count[i]) 
         return -1; 
  
    // This part calculates the number of operations required 
    int res = 0; 
    for (int i=n-1, j=n-1; i>=0; ) 
    { 
        
        while (i>=0 && A[i] != B[j]) 
        { 
            i--; 
            res++; 
        } 
  
        // If A[i] and B[j] match 
        if (i >= 0) 
        { 
            i--; 
            j--; 
        } 
    } 
    return res; 
} 

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++

/*
 * 
 * 
         _Likhon_
 *
 * 
 */ 
#include<stdio.h>
#include<string.h>
int main() {
    unsigned long long n = 2*100000;
    int cnt=0,len1,len2;
   char left[n];
   char rit[n];
   gets(left);
   gets(rit);
   len1 = strlen(left);
   len2 = strlen(rit);
   if(len1==len2)
    {
	for(int i=0;i<len1;i++)
	{
          if(left[i]!=rit[i])
           {
	    ++cnt;
	   }
	}
    }
   printf("%d" , cnt);
   return 0;
}






Compiler output:
a.cc: In function 'int main()':
a.cc:15:4: error: 'gets' was not declared in this scope; did you mean 'getw'?
   15 |    gets(left);
      |    ^~~~
      |    getw
Language: C

#include <bits/stdc++.h>
 
int main(void){
    char a[20000], b[20000];
    int s=0, i=0;
 
    scanf("%s",a);
    scanf("%s",b);
 
    while(a[i]!='\0'){
        if(a[i] != b[i]){
            a[i] = b[i];
            s++;
        }
        i++;
    }
    printf("%d",s);
    return 0;
}

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

#include <stdio.h>
int main()
{
 char a[200000];
char b[200000];
gets(a);
fflush(stdin);
gets(b);
int b;
int c=0;
int s=0;
for(int i=0;i<200000;i++)
{
if (a[i]==0) 
{
 b=i;c=1;
}
if(c==1) braek;
}
for(int x=0;x<=b;x++)
{
if(a[x]==b[x]) s++;
}
printf("%d",s);

}


Compiler output:
main.c: In function 'main':
main.c:6:1: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    6 | gets(a);
      | ^~~~
      | fgets
main.c:9:5: error: conflicting types for 'b'; have 'int'
    9 | int b;
      |     ^
main.c:5:6: note: previous declaration of 'b' with type 'char[200000]'
    5 | char b[200000];
      |      ^
main.c:18:10: error: 'braek' undeclared (first use in this function)
   18 | if(c==1) braek;
      |          ^~~~~
main.c:18:10: note: each undeclared identifier is reported only once for each function it appears in
Language: C++

#include <iostream>	
using namespace std;
 
main() {
  char S,T;
  int i=0;
  int c=0;
	cin >> S;
  	cin >>T;
  for(i=0;S[i]!='\0';i++){
  	if(S[i]==T[i]){
    	c++;
    }
    i++;
  }
  cout << c;
		return 0;
	}

Compiler output:
a.cc:4:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    4 | main() {
      | ^~~~
a.cc: In function 'int main()':
a.cc:10:12: error: invalid types 'char[int]' for array subscript
   10 |   for(i=0;S[i]!='\0';i++){
      |            ^
a.cc:11:13: error: invalid types 'char[int]' for array subscript
   11 |         if(S[i]==T[i]){
      |             ^
a.cc:11:19: error: invalid types 'char[int]' for array subscript
   11 |         if(S[i]==T[i]){
      |                   ^
Language: C++

#include <iostream>	
using namespace std;
 
main() {
  char S,T;
  int i=0;
  int c=0;
	cin >> S;
  	cin >>T;
  for(i=0;i=sizeof(S);i++){
  	if(S[i]==T[i]){
    	c++;
    }
    i++;
  }
  cout << c;
		return 0;
	}

Compiler output:
a.cc:4:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    4 | main() {
      | ^~~~
a.cc: In function 'int main()':
a.cc:11:13: error: invalid types 'char[int]' for array subscript
   11 |         if(S[i]==T[i]){
      |             ^
a.cc:11:19: error: invalid types 'char[int]' for array subscript
   11 |         if(S[i]==T[i]){
      |                   ^
Language: C++

#include<stdio.h>
#include<string.h>
int main()
{
    long long co,len,l,i,j,b;
    char s[1000001],t[1000001];
    gets(s);
    gets(t);
    len=strlen(s);
    l=strlen(t);
    co=0;
    for(i=0;i<len;i++){
        for(i=0;i<l;i++){
            if(s[i]!=t[i]){
                co++;
            }
        }
    }
    printf("%lld\n",co);

    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
    7 |     gets(s);
      |     ^~~~
      |     getw
Language: C++

#include <iostream>	
using namespace std;
 
main() {
  char S[200000],T[200000];
  int i=0;
  int c=0;
	cin >> S;
  	cin >>T;
  while(S[i]==’\0’){
  	if(S[i]==T[i]){
    	c++;
    }
    i++;
  }
  cout << c;
		return 0;
	}

Compiler output:
a.cc:10:15: error: extended character ’ is not valid in an identifier
   10 |   while(S[i]==’\0’){
      |               ^
a.cc:10:16: error: stray '\' in program
   10 |   while(S[i]==’\0’){
      |                ^
a.cc:10:17: error: extended character ’ is not valid in an identifier
   10 |   while(S[i]==’\0’){
      |                 ^
a.cc:4:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    4 | main() {
      | ^~~~
a.cc: In function 'int main()':
a.cc:10:15: error: '\U00002019' was not declared in this scope
   10 |   while(S[i]==’\0’){
      |               ^
a.cc:10:16: error: expected ')' before numeric constant
   10 |   while(S[i]==’\0’){
      |        ~       ^~~
      |                )
a.cc:10:17: error: unable to find numeric literal operator 'operator""\U00002019'
   10 |   while(S[i]==’\0’){
      |                 ^~
Language: Java

package javaapplication166;

import java.util.Scanner;

public class JavaApplication166 {

    public static void main(String[] args) {
        String S, T;
        Scanner scan = new Scanner(System.in);
        S = scan.next();
        T = scan.next();

        int a = 0, p;
        p = S.length();
        String[] data = S.split("");
        String[] info = T.split("");
        for (int i = 0; i < p; i++) {
            if (data[i].equals(info[i])) {

            } else {
                a++;

            }
        }
        System.out.print(a);
    }

}


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

/*
 * 
 * 
         _Likhon_
 *
 * 
 */ 
#include<stdio.h>
#include<string.h>
int main() {
    long long len,n = 2*100000;
    int cnt=0;
   char left[n];
   char rit[n];
   gets(left);
   gets(rit);
   len = strlen(left);
   for(int i=0;i<len;i++)
   {
       if(left[i]!=rit[i])
        {
	   ++cnt;
	}
   }
   printf("%d" , cnt);
   return 0;
}






Compiler output:
a.cc: In function 'int main()':
a.cc:15:4: error: 'gets' was not declared in this scope; did you mean 'getw'?
   15 |    gets(left);
      |    ^~~~
      |    getw
Language: C++

#include <iostream>	
using namespace std;
 
main() {
  char S[200000],T[200000];
  int i=0;
  int c=0;
	cin >> S;
  	cin >>T;
  while(S[i]==`\0`){
  	if(S[i]==T[i]){
    	c++;
    }
    i++;
  }
  cout << c;
		return 0;
	}

Compiler output:
a.cc:10:15: error: stray '`' in program
   10 |   while(S[i]==`\0`){
      |               ^
a.cc:10:16: error: stray '\' in program
   10 |   while(S[i]==`\0`){
      |                ^
a.cc:10:18: error: stray '`' in program
   10 |   while(S[i]==`\0`){
      |                  ^
a.cc:4:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    4 | main() {
      | ^~~~
Language: C


#include <stdio.h>

int main()
{
   char s1[500],s2[500];
   fgets(s1);
   fgets(s2);
   int count=0;
   for(int i=0;s1[i]!='\0';i++)
   {
       if(s1[i]!=s2[i])
       {
           count++;
       }
   }
printf("%d",count);
    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:7:4: error: too few arguments to function 'fgets'
    7 |    fgets(s1);
      |    ^~~~~
In file included from main.c:2:
/usr/include/stdio.h:654:14: note: declared here
  654 | extern char *fgets (char *__restrict __s, int __n, FILE *__restrict __stream)
      |              ^~~~~
main.c:8:4: error: too few arguments to function 'fgets'
    8 |    fgets(s2);
      |    ^~~~~
/usr/include/stdio.h:654:14: note: declared here
  654 | extern char *fgets (char *__restrict __s, int __n, FILE *__restrict __stream)
      |              ^~~~~
Language: Java

import java.util.*;
public class main
{
    public static void main(String[] args)
    {
        String S,T;
        Scanner si=new Scanner(System.in);
        S=si.nextLine();
        T=si.nextLine();
        int i,j=0,count=0;
        for(i=0;i<S.length();i++)
        {
            if(S.charAt(i)!=T.charAt(j))
            {
                count++;
                j++;
            }
            else
            {
                j++;
            }
        }
        System.out.println(count);
    }
}

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

#include <iostream>	
using namespace std;
 
main() {
  char S[200000],T[200000];
  int i=0;
  int c=0;
	cin >> S;
  	cin >>T;
  while(S[i]==\0){
  	if(S[i]==T[i]){
    	c++;
    }
    i++;
  }
  cout << c;
 
		return 0;
	}

Compiler output:
a.cc:10:15: error: stray '\' in program
   10 |   while(S[i]==\0){
      |               ^
a.cc:4:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    4 | main() {
      | ^~~~
Language: C++

#include<stdio.h>
#include<string.h>
int main()
{
    long long co,len,l,i,j,b;
    char s[10001],t[10001];
    gets(s);
    gets(t);
    len=strlen(s);
    l=strlen(t);
    co=0;
    for(i=0;i<len;i++){
        for(i=0;i<l;i++){
            if(s[i]==t[i]){
                co++;
            }
        }
    }
    printf("%lld\n", l-co);

    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
    7 |     gets(s);
      |     ^~~~
      |     getw
Language: Java

package javaapplication166;

import java.util.Scanner;

public class JavaApplication166 {

    public static void main(String[] args) {
        String S, T;
        Scanner scan = new Scanner(System.in);
        S = scan.next();
        T = scan.next();

        int a = 0, p;
        p = S.length();
        String[] data = S.split("");
        String[] info = T.split("");

        for (int i = 0; i < p; i++) {
            if (data[i].equals(info[i])) {

            } else {
                a++;

            }
        }
        System.out.println(a);
    }

}


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

#include <iostream>	
using namespace std;
 
main() {
  char S,T;
  int i=0;
  int c=0;
	cin >> S;
  	cin >>T;
  while(S[i]==\0){
  	if(S[i]==T[i]){
    	c++;
    }
    i++;
  }
  cout << c;
 
		return 0;
	}

Compiler output:
a.cc:10:15: error: stray '\' in program
   10 |   while(S[i]==\0){
      |               ^
a.cc:4:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    4 | main() {
      | ^~~~
a.cc: In function 'int main()':
a.cc:10:10: error: invalid types 'char[int]' for array subscript
   10 |   while(S[i]==\0){
      |          ^
a.cc:11:13: error: invalid types 'char[int]' for array subscript
   11 |         if(S[i]==T[i]){
      |             ^
a.cc:11:19: error: invalid types 'char[int]' for array subscript
   11 |         if(S[i]==T[i]){
      |                   ^
Language: C++

#include <iostream>	
using namespace std;
 
main() {
  char S,T;
  int i=0;
  int c=0;
	cin >> S;
  	cin >>T;
  while(S[i]==\0;){
  	if(S[i]==T[i]){
    	c++;
    }
    i++;
  }
  cout << c;
 
		return 0;
	}

Compiler output:
a.cc:10:15: error: stray '\' in program
   10 |   while(S[i]==\0;){
      |               ^
a.cc:4:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    4 | main() {
      | ^~~~
a.cc: In function 'int main()':
a.cc:10:10: error: invalid types 'char[int]' for array subscript
   10 |   while(S[i]==\0;){
      |          ^
a.cc:10:17: error: expected ')' before ';' token
   10 |   while(S[i]==\0;){
      |        ~        ^
      |                 )
a.cc:10:18: error: expected primary-expression before ')' token
   10 |   while(S[i]==\0;){
      |                  ^
Language: C++

#include <iostream>	
using namespace std;
 
main() {
  cahr S,T;
  int i=0;
  int c=0;
	cin >> S;
  	cin >>T;
  while(S[i]==\0;){
  	if(S[i]==T[i]){
    	c++;
    }
    i++;
  }
  cout << c;
 
		return 0;
	}

Compiler output:
a.cc:10:15: error: stray '\' in program
   10 |   while(S[i]==\0;){
      |               ^
a.cc:4:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    4 | main() {
      | ^~~~
a.cc: In function 'int main()':
a.cc:5:3: error: 'cahr' was not declared in this scope; did you mean 'char'?
    5 |   cahr S,T;
      |   ^~~~
      |   char
a.cc:8:16: error: 'S' was not declared in this scope
    8 |         cin >> S;
      |                ^
a.cc:9:15: error: 'T' was not declared in this scope
    9 |         cin >>T;
      |               ^
a.cc:10:17: error: expected ')' before ';' token
   10 |   while(S[i]==\0;){
      |        ~        ^
      |                 )
a.cc:10:18: error: expected primary-expression before ')' token
   10 |   while(S[i]==\0;){
      |                  ^
Language: Java

import scanner;
Scanner sc=new Scanner(System.in);  

String x = sc.nextLine();
String y = sc.nextLine();
int counter = 0;

for(int i = 0 ; i < x.length(); i++){
  if(! x.charAt(i).equals(y.charAt(i))){
    counter++;
  }
}
System.out.println(counter);

Compiler output:
Main.java:1: error: '.' expected
import scanner;
              ^
Main.java:2: error: unnamed classes are a preview feature and are disabled by default.
Scanner sc=new Scanner(System.in);  
^
  (use --enable-preview to enable unnamed classes)
Main.java:8: error: class, interface, enum, or record expected
for(int i = 0 ; i < x.length(); i++){
^
Main.java:8: error: class, interface, enum, or record expected
for(int i = 0 ; i < x.length(); i++){
                ^
Main.java:8: error: class, interface, enum, or record expected
for(int i = 0 ; i < x.length(); i++){
                                ^
Main.java:11: error: class, interface, enum, or record expected
  }
  ^
6 errors
Language: Java

import java.util.*;

public class Main{
	public static void main(String[] args){
    	Scanner sc = new Scanner(System.in);
    	String s = sc.nextLine();
      	int count = 0;
      	sc.hasNext();
      	String t = sc.nextLine();
      	for(char i=0; i<s.length(); i++){
        	if(s.charAt[i] != t.charAt[i]){
            	s.charAt[i] = t.charAt[i];
              	count++;
            }
        }
      	System.out.println(count);
    }
}



Compiler output:
Main.java:11: error: cannot find symbol
        	if(s.charAt[i] != t.charAt[i]){
        	    ^
  symbol:   variable charAt
  location: variable s of type String
Main.java:11: error: cannot find symbol
        	if(s.charAt[i] != t.charAt[i]){
        	                   ^
  symbol:   variable charAt
  location: variable t of type String
Main.java:12: error: cannot find symbol
            	s.charAt[i] = t.charAt[i];
            	 ^
  symbol:   variable charAt
  location: variable s of type String
Main.java:12: error: cannot find symbol
            	s.charAt[i] = t.charAt[i];
            	               ^
  symbol:   variable charAt
  location: variable t of type String
4 errors
Language: Java

import java.util.*;
public class Main {
	public static void main(String[] args){
       Scanner sc = new Scanner(System.in);
      
      //文字列Sの取得
      String S = sc.nextline();
      //文字列Tの取得
      String T = sc.nextline();
 
      //置き換え回数
      int count = 0;
      
      for (int i = 0; i < S.length(); i++) {
            char s = strS.charAt(i);
            char t = strT.charAt(i);
            
            if (!(s == t)) {
               count++;
            }
      }
 
		System.out.println(count);
    }
}

Compiler output:
Main.java:7: error: cannot find symbol
      String S = sc.nextline();
                   ^
  symbol:   method nextline()
  location: variable sc of type Scanner
Main.java:9: error: cannot find symbol
      String T = sc.nextline();
                   ^
  symbol:   method nextline()
  location: variable sc of type Scanner
Main.java:15: error: cannot find symbol
            char s = strS.charAt(i);
                     ^
  symbol:   variable strS
  location: class Main
Main.java:16: error: cannot find symbol
            char t = strT.charAt(i);
                     ^
  symbol:   variable strT
  location: class Main
4 errors
Language: C++

#include <bits/stdc++.h> 

using namespace std; 
#define ll long long
#define ld long double

int main()
{
  string s,t;
  cin >> s >> t;
  ll ans=0;
  for(ll i=0;i<s.size();i++)
  {
    if(s[i]!=t[i])
      ans+=1;
  }
  cout << ans;

Compiler output:
a.cc: In function 'int main()':
a.cc:17:15: error: expected '}' at end of input
   17 |   cout << ans;
      |               ^
a.cc:8:1: note: to match this '{'
    8 | {
      | ^
Language: C++

#include<cstdio>
#include<cstring>
#include<iostream>
using namespace std;
char s[200005],t[200005];
int main(){
	scanf("%s",c+1);
	scanf("%s",t+1);
	int d=0;
	for(int i=1;i<=200005;i++){
		if(s[i]==0) break;
		if(s[i]!=t[i]){
			d++;
		}
	}
	printf("%d",d);
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:20: error: 'c' was not declared in this scope
    7 |         scanf("%s",c+1);
      |                    ^
Language: Java

mport java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		String S = scan.next();
		String T = scan.next();
		scan.close();

		String[] sArray = S.split("");
		String[] tArray = T.split("");

		int count = 0;
		for (int i = 0; i < sArray.length; i++) {
			if (!sArray[i].equals(tArray[i])) {
				count += 1;
			}
		}
		System.out.println(count);
	}
}

Compiler output:
Main.java:1: error: class, interface, enum, or record expected
mport java.util.Scanner;
^
1 error
Language: Java

import java.util.*;
public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
      
      //文字列Sの取得
      　 String strS = sc.nextline();
 
      //文字列Tの取得
      　String strT = sc.nextline();
 
      //置き換え回数
      int count = 0;
      
      for (int i = 0; i < strS.length(); i++) {
            char s = strS.charAt(i);
            char t = strT.charAt(i);
            
            if (!(s == t)) {
               count++;
            }
      }
 
		System.out.println(count);
    }
}

Compiler output:
Main.java:7: error: illegal character: '\u3000'
      ? String strS = sc.nextline();
      ^
Main.java:10: error: illegal character: '\u3000'
      ?String strT = sc.nextline();
      ^
2 errors
Language: C++

#include<cstdio>
#include<cstring>
#include<iostream>
using namespace std;
char s[10086],t[10086];
int main(){
	scanf("%s",c+1);
	scanf("%s",t+1);
	long long d=0;
	for(int i=0;i<=10086;i++){
		if(s[i]==0) break;
		if(s[i]!=t[i]){
			d++;
		}
	}
	printf("%d",d);
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:20: error: 'c' was not declared in this scope
    7 |         scanf("%s",c+1);
      |                    ^
Language: C++

// Function to find minimum number of operations required to transform 
// A to B. 
int minOps(string& A, string& B) 
{ 
    int m = A.length(), n = B.length(); 
  
     // This parts checks whether conversion is 
     // possible or not 
    if (n != m) 
       return -1; 
    int count[256]; 
    memset(count, 0, sizeof(count)); 
    for (int i=0; i<n; i++)   // count characters in A 
       count[B[i]]++; 
    for (int i=0; i<n; i++)   // subtract count for 
       count[A[i]]--;         // every character in B 
    for (int i=0; i<256; i++)   // Check if all counts become 0 
      if (count[i]) 
         return -1; 
  
    // This part calculates the number of operations required 
    int res = 0; 
    for (int i=n-1, j=n-1; i>=0; ) 
    { 
        // If there is a mismatch, then keep incrementing 
        // result 'res' until B[j] is not found in A[0..i] 
        while (i>=0 && A[i] != B[j]) 
        { 
            i--; 
            res++; 
        } 
  
        // If A[i] and B[j] match 
        if (i >= 0) 
        { 
            i--; 
            j--; 
        } 
    } 
    return res; 
} 

Compiler output:
a.cc:3:12: error: 'string' was not declared in this scope
    3 | int minOps(string& A, string& B)
      |            ^~~~~~
a.cc:3:20: error: 'A' was not declared in this scope
    3 | int minOps(string& A, string& B)
      |                    ^
a.cc:3:23: error: 'string' was not declared in this scope
    3 | int minOps(string& A, string& B)
      |                       ^~~~~~
a.cc:3:31: error: 'B' was not declared in this scope
    3 | int minOps(string& A, string& B)
      |                               ^
a.cc:3:32: error: expression list treated as compound expression in initializer [-fpermissive]
    3 | int minOps(string& A, string& B)
      |                                ^
Language: C

cupofcoffee
cupofhottea

Compiler output:
main.c:1:1: error: unknown type name 'cupofcoffee'
    1 | cupofcoffee
      | ^~~~~~~~~~~
main.c:2:1: error: expected '=', ',', ';', 'asm' or '__attribute__' at end of input
    2 | cupofhottea
      | ^~~~~~~~~~~
Language: Java

import java.util.*;
public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
      
      //文字列Sの取得
      　 String strS = sc.next();
 
      //文字列Tの取得
      　String strT = sc.next();
 
      //置き換え回数
      int count = 0;
      
      for (int i = 0; i < strS.length(); i++) {
            char s = strS.charAt(i);
            char t = strT.charAt(i);
            
            if (!(s == t)) {
               count++;
            }
      }
 
		System.out.println(count);
    }
}

Compiler output:
Main.java:7: error: illegal character: '\u3000'
      ? String strS = sc.next();
      ^
Main.java:10: error: illegal character: '\u3000'
      ?String strT = sc.next();
      ^
2 errors
Language: C++

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

int main(){
  string s,t;
  cin >> s >> t;

  int a= s.length();
   char c[a] = s;
   char d[a] = t;

   int e=0;

   for(int i=0; i<a; i++){
     if(c[i] != d[i]){
       e++;
     }
   }

   cout << e << endl;
   return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:16: error: array must be initialized with a brace-enclosed initializer
    9 |    char c[a] = s;
      |                ^
a.cc:10:16: error: array must be initialized with a brace-enclosed initializer
   10 |    char d[a] = t;
      |                ^
Language: C++

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

int main(){
  string s,t;
  cin >> s >> t;

  int a= s.length();
   char c[a];
   char d[a];

   int e=0;

   for(int i=0 i<a; i++){
     if(c[i] != d[i]){
       e++;
     }
   }

   cout << e << endl;
   return 0;
}

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

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

string S,T;
int main()
{
   	cin >> S;
   	cin >> T;
   	int total = 0;
  	for(int i=0;i<S.length();i++){
        if S[i]!=T[i]:
            total += 1
  	}
  	cout << total <<endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:12:12: error: expected '(' before 'S'
   12 |         if S[i]!=T[i]:
      |            ^
      |            (
Language: C

#include <stdio.h>
#include <string.h>
#define NUMBER 200001
int main()
{
  char s[NUMBER],t[NUMBER];
  scanf("%s", s);
  scanf("%s", t);
  int i,cnt=0,len=0;
  while(s[len])
    len++;
  for(i=0,i<len;i++){
    if(s[i] == t[i])
    continue;
    else
    cnt++;
  }
printf("%d", cnt);
  return 0;
}


Compiler output:
main.c: In function 'main':
main.c:12:20: error: expected ';' before ')' token
   12 |   for(i=0,i<len;i++){
      |                    ^
      |                    ;
Language: C

#include <stdio.h>
#include <string.h>
int main()
{
    char s[100], t[100];
    int n, i, cnt=0;
    scanf("%s%s", %s, &t);
    n=strlen(s);
    for(i=0; i<n; i++) {
        if(s[i]!=t[i])
            cnt++;
    }
    printf("%d\n", cnt);
    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:7:19: error: expected expression before '%' token
    7 |     scanf("%s%s", %s, &t);
      |                   ^
Language: C

#include <stdio.h>
#include <string.h>
int main()
{
    char s[], t[];
    int n, i, cnt=0;
    scanf("%s%s", s, t);
    n=strlen(s);
    for(i=0; i<n; i++) {
        if(s[i]!=t[i])
            cnt++;
    }
    printf("%d\n", cnt);
    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:5:10: error: array size missing in 's'
    5 |     char s[], t[];
      |          ^
main.c:5:15: error: array size missing in 't'
    5 |     char s[], t[];
      |               ^
Language: C++

    #include<iostream>
    using namespace std;
    int main(){
      char a[200000]={};
      char b[200000]={};
      cin>>b;
      char d='';
      int d=0;
      
      for(int d=0; d<=200000; d++){
        cin>>a[d];
      }
      for(int e=0; e<=200000; e++){
        cin>>b[e];
      }
      for(int f=0; f<=200000; f++){
        a[f]=b[f]
        if(a[f]!=b[f]){
          d++
        }
       }
      cout<<d;
    }

#include<iostream>
using namespace std;
int main(){
  char a[200000]={};
  char b[200000]={};
  cin>>b;
  char d='';
  int d=0;
  
  for(int d=0; d<=200000; d++){
    cin>>a[d];
  }
  for(int e=0; e<=200000; e++){
    cin>>b[e];
  }
  for(int f=0; f<=200000; f++){
    a[f]=b[f]
    if(a[f]!=b[f]){
      d++
    }
   }
  cout<<d;
}

Compiler output:
a.cc:7:14: error: empty character constant
    7 |       char d='';
      |              ^~
a.cc:31:10: error: empty character constant
   31 |   char d='';
      |          ^~
a.cc: In function 'int main()':
a.cc:8:11: error: conflicting declaration 'int d'
    8 |       int d=0;
      |           ^
a.cc:7:12: note: previous declaration as 'char d'
    7 |       char d='';
      |            ^
a.cc:17:18: error: expected ';' before 'if'
   17 |         a[f]=b[f]
      |                  ^
      |                  ;
   18 |         if(a[f]!=b[f]){
      |         ~~        
a.cc: At global scope:
a.cc:27:5: error: redefinition of 'int main()'
   27 | int main(){
      |     ^~~~
a.cc:3:9: note: 'int main()' previously defined here
    3 |     int main(){
      |         ^~~~
a.cc: In function 'int main()':
a.cc:32:7: error: conflicting declaration 'int d'
   32 |   int d=0;
      |       ^
a.cc:31:8: note: previous declaration as 'char d'
   31 |   char d='';
      |        ^
a.cc:41:14: error: expected ';' before 'if'
   41 |     a[f]=b[f]
      |              ^
      |              ;
   42 |     if(a[f]!=b[f]){
      |     ~~
Language: C++

    #include<iostream>
    using namespace std;
    int main(){
      char a[200000]={};
      char b[200000]={};
      cin>>b;
      char d='';
      int d=0;
      
      for(int d=0; d<=200000; d++){
        cin>>a[d];
      }
      for(int e=0; e<=200000; e++){
        cin>>b[e];
      }
      for(int f=0; f<=200000; f++){
        a[f]=b[f]
        if(a[f]!=b[f]){
          d++
        }
       }
      cout<<d;
    }

#include<iostream>
using namespace std;
int main(){
  char a[200000]={};
  char b[200000]={};
  cin>>b;
  char d='';
  int d=0;
  
  for(int d=0; d<=200000; d++){
    cin>>a[d];
  }
  for(int e=0; e<=200000; e++){
    cin>>b[e];
  }
  for(int f=0; f<=200000; f++){
    a[f]=b[f]
    if(a[f]!=b[f]){
      d++
    }
   }
  cout<<d;
}

Submission Info
Submission Time 	2020-06-27 18:12:14
Task 	C - Tsundoku
User 	DarshSikka
Language 	C++ (GCC 9.2.1)
Score 	0
Code Size 	356 Byte
Status 	

Compiler output:
a.cc:7:14: error: empty character constant
    7 |       char d='';
      |              ^~
a.cc:31:10: error: empty character constant
   31 |   char d='';
      |          ^~
a.cc:53:26: error: too many decimal points in number
   53 | Language        C++ (GCC 9.2.1)
      |                          ^~~~~
a.cc: In function 'int main()':
a.cc:8:11: error: conflicting declaration 'int d'
    8 |       int d=0;
      |           ^
a.cc:7:12: note: previous declaration as 'char d'
    7 |       char d='';
      |            ^
a.cc:17:18: error: expected ';' before 'if'
   17 |         a[f]=b[f]
      |                  ^
      |                  ;
   18 |         if(a[f]!=b[f]){
      |         ~~        
a.cc: At global scope:
a.cc:27:5: error: redefinition of 'int main()'
   27 | int main(){
      |     ^~~~
a.cc:3:9: note: 'int main()' previously defined here
    3 |     int main(){
      |         ^~~~
a.cc: In function 'int main()':
a.cc:32:7: error: conflicting declaration 'int d'
   32 |   int d=0;
      |       ^
a.cc:31:8: note: previous declaration as 'char d'
   31 |   char d='';
      |        ^
a.cc:41:14: error: expected ';' before 'if'
   41 |     a[f]=b[f]
      |              ^
      |              ;
   42 |     if(a[f]!=b[f]){
      |     ~~        
a.cc: At global scope:
a.cc:49:1: error: 'Submission' does not name a type
   49 | Submission Info
      | ^~~~~~~~~~
Language: Java

import java.util.*;
public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
      
      //文字列Sの取得
      　 String strS = sc.next();
     　　String[] S = strS.split("");
      //文字列Tの取得
      　String strT = sc.next();
        String[] T = strT.split("");
      
      //置き換え回数
      int count = 0;
      
      //文字列を一文字ずつ比較
        for(int=0;i<strS.length;i++){
            if (!(S[i])==(T[i])){
              count++;
            }
        }
 
		System.out.println(count);
    }
}

Compiler output:
Main.java:7: error: illegal character: '\u3000'
      ? String strS = sc.next();
      ^
Main.java:8: error: illegal character: '\u3000'
     ??String[] S = strS.split("");
     ^
Main.java:8: error: illegal character: '\u3000'
     ??String[] S = strS.split("");
      ^
Main.java:10: error: illegal character: '\u3000'
      ?String strT = sc.next();
      ^
Main.java:17: error: not a statement
        for(int=0;i<strS.length;i++){
            ^
Main.java:17: error: ';' expected
        for(int=0;i<strS.length;i++){
               ^
Main.java:17: error: not a statement
        for(int=0;i<strS.length;i++){
                   ^
Main.java:17: error: ')' expected
        for(int=0;i<strS.length;i++){
                               ^
Main.java:17: error: ';' expected
        for(int=0;i<strS.length;i++){
                                   ^
9 errors
Language: C++

#include<bits/stdc++.h>
#define ll long long
using namespace std;
int main()
{
    char a[100000], b[100000];
    gets(a);
    gets(b);
    ll k=strlen(a);
    ll l=strlen(b);
    ll c=0,i;
    if(k==l)
    {
        for(i=0;i<k;i++)
        {
            if(a[i]!=b[i])
                c++;
        }
        cout << c;
    }
    cout << endl;

}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:5: error: 'gets' was not declared in this scope; did you mean 'getw'?
    7 |     gets(a);
      |     ^~~~
      |     getw
Language: C++

#include<iostream>
#include<string>

using namespace std;

int main(){
  string S,T;
  cin >> S;
  cin >> T;
  
  int times = 0;
  for(int i=0;i<S.size();i++){
    if(S[i] != T[i]){times ++}
  }
  
  cout << times << endl;
  
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:30: error: expected ';' before '}' token
   13 |     if(S[i] != T[i]){times ++}
      |                              ^
      |                              ;
Language: C

#include<stdio.h>
#include<string.h>

int Main()
{
    int i,j=0,count=0,flag=0;
    char S[30];
    char T[30];
    scanf("%s",S);
    scanf("%s",T);
  printf("%s",S);
  printf("%s",T);
    int m=strlen(S);
    int n=strlen(T);
    for(i=0;i<m;i++)
    {
        
            if(S[i]!=T[j])
            {
                count++;
                j++;
            }
      else
      {
        j++;
      }
    }
    printf("%d",count);
    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<bits\stdc++.h>
using namespace std;
int main()
{
     int i,j,c=0;
     string s,t;
     cin>>s>>t;
     for(i=0,j=0;i<s.size();i++,j++){
          if(s[i]==t[j])
               c++;
     }
     cout<<c<<endl;

     return 0;
}


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

#include <stdio.h>
#include<string.h>

int main()
{
    char S[1000],T[1000];
    fgets(S,1000,stdin);
    fgets(t,1000,stdin);
    int l,m,i,j,c=0;
    l=strlen(S);
    m=strlen(T);
    if(l==m)
    {
        
         for(i=0;i<=l;i++)
    {
        if(S[i]!=T[i])
        {
            c++;
        }
    }
    }
    else{
        printf(" ");
    }
    printf("%d",c);
   
    

    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:8:11: error: 't' undeclared (first use in this function)
    8 |     fgets(t,1000,stdin);
      |           ^
main.c:8:11: 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(){
  vector<string>s;
  vector<string>t;

  for(int i=0; i<20001; i++){
    cin >> s[i];
  }

  for(int i=0; i<20001; i++){
    cin >> t[i];
  }

  int j=0;
  int cont =0;
  while (s[] != t[]{
    if(s[j] != t[j]){
      s[j] = t[j];
    }
    j++;
    cont++;
  }

  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:18:12: error: expected primary-expression before ']' token
   18 |   while (s[] != t[]{
      |            ^
a.cc:18:19: error: expected primary-expression before ']' token
   18 |   while (s[] != t[]{
      |                   ^
a.cc:18:20: error: expected ')' before '{' token
   18 |   while (s[] != t[]{
      |         ~          ^
      |                    )
Language: C++

#include <iostream>
#include <string>
 
using namespace std;
 
int main(){
  	string S, T;
  	cin >> S >> T;
  
  	int len = S.size(), counter = 0;
  	
	
  	if(int i = 0; i < len; i++){
      if(S[i] == T[i]) counter++;
    }
  	
  	cout << counter << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:13:30: error: expected ')' before ';' token
   13 |         if(int i = 0; i < len; i++){
      |           ~                  ^
      |                              )
a.cc:13:32: error: 'i' was not declared in this scope
   13 |         if(int i = 0; i < len; i++){
      |                                ^
Language: C

#include <stdio.h>
 
int main()
{
  
  char s[101];
  char t[101];
  
  scanf("%s",t);
  scanf("%s",s);
  for(int i = 0; int n = 0; s[i] != '\0'; i++) {
    if (s[i] != t[i])
      n++;
  }
    printf("%d\n", n);
    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:11:18: error: expected expression before 'int'
   11 |   for(int i = 0; int n = 0; s[i] != '\0'; i++) {
      |                  ^~~
main.c:11:41: error: expected ')' before ';' token
   11 |   for(int i = 0; int n = 0; s[i] != '\0'; i++) {
      |      ~                                  ^
      |                                         )
main.c:13:7: error: 'n' undeclared (first use in this function)
   13 |       n++;
      |       ^
main.c:13:7: note: each undeclared identifier is reported only once for each function it appears in
Language: Java

import java.util.*;
public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
      
      //文字列Sの取得
      　String strS = sc.next();
     　　String[] S = strS.split("");
      //文字列Tの取得
      　String strT = sc.next();
        String[] T = strT.split("");
      
      //置き換え回数
      int count = 0;
      
      //文字列を一文字ずつ比較
        for(int=0;i<S.length;i++){
            if (!S[i]equals(T[i])){
              count++;
        }

		System.out.println(count);
	}
}

Compiler output:
Main.java:7: error: illegal character: '\u3000'
      ?String strS = sc.next();
      ^
Main.java:8: error: illegal character: '\u3000'
     ??String[] S = strS.split("");
     ^
Main.java:8: error: illegal character: '\u3000'
     ??String[] S = strS.split("");
      ^
Main.java:10: error: illegal character: '\u3000'
      ?String strT = sc.next();
      ^
Main.java:17: error: not a statement
        for(int=0;i<S.length;i++){
            ^
Main.java:17: error: ';' expected
        for(int=0;i<S.length;i++){
               ^
Main.java:17: error: not a statement
        for(int=0;i<S.length;i++){
                   ^
Main.java:17: error: ')' expected
        for(int=0;i<S.length;i++){
                            ^
Main.java:17: error: ';' expected
        for(int=0;i<S.length;i++){
                                ^
Main.java:18: error: ')' expected
            if (!S[i]equals(T[i])){
                     ^
Main.java:18: error: ';' expected
            if (!S[i]equals(T[i])){
                                 ^
Main.java:24: error: reached end of file while parsing
}
 ^
12 errors
Language: C

#include<stdio.h>
#include<string.h>
int main (void){
 char S[2*10*10*10*10*10*10];
 char T[2*10*10*10*10*10*10]];
 int len;
 int i,j;
 j=0;
 scanf("%s",S);
 scanf("%s",T);
len = strlen(S);
for(i = 0;i <= len;i++){
     if(S[i] != T[i]){
         j++;
     }
     
}
     printf("%d",j);
}
 

Compiler output:
main.c: In function 'main':
main.c:5:29: error: expected '=', ',', ';', 'asm' or '__attribute__' before ']' token
    5 |  char T[2*10*10*10*10*10*10]];
      |                             ^
main.c:5:29: error: expected statement before ']' token
main.c:10:13: error: 'T' undeclared (first use in this function)
   10 |  scanf("%s",T);
      |             ^
main.c:10:13: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include <stdio.h>
int main(){
  char str1[],str2[];
  int len=0,i,count=0;
  scanf("%s",str1);
  scanf("%s",str2);
  while(str1[len]){
    len++;
  }
  for(i=0;i<len;i++){
    if(str1[i] != str2[i]){
      count++;
    }
  }
    printf("%d",count);
}

Compiler output:
main.c: In function 'main':
main.c:3:8: error: array size missing in 'str1'
    3 |   char str1[],str2[];
      |        ^~~~
main.c:3:15: error: array size missing in 'str2'
    3 |   char str1[],str2[];
      |               ^~~~
Language: C

#include <stdio.h>
signed main(){
char s[100000]={};
char t[100000]={};
int i=0,count=0,ii=0;
 while(s[i]!=\0){
  scanf("%c",s[i]);
   i++;
  }
  i=0;
while(t[i]!=\0){
   scanf("%c",t[i]);
  i++;
  }
	
printf("%s %s\n",s[1],t[1]);
 

 
for(ii=0;ii<i;ii++){
	if(s[ii]!=t[ii]){
		count++;
	}
}

printf("%d\n",count);
  
return(0);
}

Compiler output:
main.c: In function 'main':
main.c:6:14: error: stray '\' in program
    6 |  while(s[i]!=\0){
      |              ^
main.c:11:13: error: stray '\' in program
   11 | while(t[i]!=\0){
      |             ^
Language: Java

import java.util.Scanner;

public class Main{
	public static void main(String args[]){
      Scanner sc = new Scanner(System.in);
      
      String s = sc.next();
      String t = sc.next();
      
      if(s.equals(t)){
        System.out.print("0");
        return;
      }
        
      
      int result = 0;
      for(int i=0; i < s.length(); i++){
      	if(!s.substring(i,i+1),equals(t.substring(i, i+1))){
          result++;
        }
      }
        
      System.out.print(result);
    }
}


Compiler output:
Main.java:18: error: ')' expected
      	if(!s.substring(i,i+1),equals(t.substring(i, i+1))){
      	                      ^
Main.java:18: error: ';' expected
      	if(!s.substring(i,i+1),equals(t.substring(i, i+1))){
      	                                                  ^
2 errors