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

#include <stdio.h>
int main(){
  char string[10];
  int i,n,count=0;
  scanf("%d",&n);
  for(i=0;i<=n-1;i++)
    scanf("%c",string[i]);
  for(i=0;i<=n-1;i++){
    if(string[i]=='A')
      ++count;
   else if(string[i]=='T')
      ++count;
    else if(string[i]=='G')
      ++count;
    else if string[i]'C')
      ++count;
  }
  printf("%d",count);
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:15:13: error: expected '(' before 'string'
   15 |     else if string[i]'C')
      |             ^~~~~~
      |             (
main.c:15:25: error: expected statement before ')' token
   15 |     else if string[i]'C')
      |                         ^
Language: C

#include <stdio.h>
int main(){
  char string[10];
  int i,n,count=0;
  scanf("%d",&n);
  for(i=0;i<=n-1;i++)
    scanf("%c",&string[i]);
  for(i=0;i<=n-1;i++){
    if(string[j]=='A')
      ++count;
   if(string[j]=='T')
      ++count;
    if(string[j]=='G')
      ++count;
    if(string[j]=='C')
      ++count;
  }
  printf("%d",count);
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:9:15: error: 'j' undeclared (first use in this function)
    9 |     if(string[j]=='A')
      |               ^
main.c:9:15: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include<stdio.h>
int check(char c){
  if(c=='A') return 1;
  if(c=='T') return 1;
  if(c=='G') return 1;
  if(c=='C') return 1;
  return 0;
}
int main(void){
  char str[11];
  scanf("%s",str);
  int i =0;
  int j= 0;
  while(str[j]!=0)j++;
  while(check(str[i])){
    i++;
  }
  while(j<=0&&check(str[j])){
    j--;
  }
  int n=j-i;
  for(i=i+1;i<j;i++){
    if(check(str[c])!=0){
      printf("0");
      return 0;
    }
    
    printf("%d",n);
  }
}


Compiler output:
main.c: In function 'main':
main.c:23:18: error: 'c' undeclared (first use in this function)
   23 |     if(check(str[c])!=0){
      |                  ^
main.c:23:18: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include<stdio.h>
int check(char c){
  if(c=='A') return 1;
  if(c=='T') return 1;
  if(c=='G') return 1;
  if(c=='C') return 1;
  return 0;
}
int main(void){
  char str[11];
  scanf("%s",str);
  int i =0;
  int j= 0;
  while(str[j]!=0)j++;
  while(check(str[i])){
    i++;
  }
  while(check(j<=0&&check(str[j])){
    j--;
  }
  int n=j-i;
  for(i=i+1;i<j;i++){
    if(check(str[c])!=0){
      printf("0");
      return 0;
    }
    
    printf("%d",n);
  }
}


Compiler output:
main.c: In function 'main':
main.c:18:35: error: expected ')' before '{' token
   18 |   while(check(j<=0&&check(str[j])){
      |        ~                          ^
      |                                   )
main.c:30:1: error: expected expression before '}' token
   30 | }
      | ^
Language: C

#include<stdio.h>
int check(char c){
  if(c=='A') return 1;
  if(c=='T') return 1;
  if(c=='G') return 1;
  if(c=='C') return 1;
  return 0;
}
int main(void){
  char[11] str;
  scanf("%s",str);
  int i =0;
  int j= 0;
  while(str[j]!=0)j++;
  while(check(str[i]){
    i++;
  }
  while(check(j<=0&&check(str[j])){
    j--;
  }
  int n=j-i;
  for(i=i+1;i<j;i++){
    if(check(str[c])!=0){
      printf("0");
      return 0;
    }
    
    printf("%d",n);
  }
}

Compiler output:
main.c: In function 'main':
main.c:10:7: error: expected identifier or '(' before '[' token
   10 |   char[11] str;
      |       ^
main.c:11:14: error: 'str' undeclared (first use in this function)
   11 |   scanf("%s",str);
      |              ^~~
main.c:11:14: note: each undeclared identifier is reported only once for each function it appears in
main.c:15:22: error: expected ')' before '{' token
   15 |   while(check(str[i]){
      |        ~             ^
      |                      )
main.c:30:1: error: expected declaration or statement at end of input
   30 | }
      | ^
Language: C++

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

nt main()
{
  string S; cin >> S;

  int N = S.size();
  int ans = 0;
  int pre_ans = 0;

  for (int i = 0; i < N; i++)
  {
    if (S[i]=='A' or S[i]=='C' or S[i] == 'G' or S[i] == 'T')
    {
      pre_ans++;
    }
    else
    {
      if (pre_ans > ans)
      {
        ans = pre_ans;
        pre_ans = 0; 
      }
    }
  }

  cout << ans << endl;

}

Compiler output:
a.cc:4:1: error: 'nt' does not name a type; did you mean 'int'?
    4 | nt main()
      | ^~
      | int
Language: Java

import java.util.*;
public class Main {
	public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        
        String S = sc.next();
        
        String[] ar = S.split("");

        int maxLength = 0;
        int tmp = 0;

        for (int i = 0; i < ar.length(); i++){
            
            if (ar[i].equals("A") || ar[i].equals("T") || ar[i].equals("G") || ar[i].equals("C")) {
                tmp++;
            } else {
                tmp = 0;
            }

            if (tmp > maxLength) {
                maxLength = tmp;
            }

        }

        System.out.println(maxLength);
     }
}

Compiler output:
Main.java:13: error: cannot find symbol
        for (int i = 0; i < ar.length(); i++){
                              ^
  symbol:   method length()
  location: variable ar of type String[]
1 error
Language: C++

#include <iostream>
#include <string>
using namespace std;
int main(){
  string s; cin >> s;
  int count = 0;
  int ans = 0;
  for(int i = 0;i < 10;i++){
    if(s.substr(i,1)=="A"||s.substr(i,1)=="T"||s.substr(i,1)=="G"||s.substr(i,1)=="C"){
      count++;
    }else{
      if(count > ans){
        ans = count;
      }
      count = 0
    }
  }
  cout << ans << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:15:16: error: expected ';' before '}' token
   15 |       count = 0
      |                ^
      |                ;
   16 |     }
      |     ~
Language: C++

#include <iostream>
#include <string>
using namespace std;
int main(){
  string s; cin >> s;
  int count = 0;
  int ans = 0;
  for(int i = 0;i < 10;i++){
    if(s.substr(i,1)=="A"||s.substr(i,1)=="T"||s.substr(i,1)=="G"||s.substr(i,1)=="C"){
      count++;
    }else{
      if(count > ans){
        ans = count
      }
      count = 0
    }
  }
  cout << ans << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:20: error: expected ';' before '}' token
   13 |         ans = count
      |                    ^
      |                    ;
   14 |       }
      |       ~             
a.cc:15:16: error: expected ';' before '}' token
   15 |       count = 0
      |                ^
      |                ;
   16 |     }
      |     ~
Language: C++

#include <bits/stdc++.h>
#include <numeric>
#include<iostream>
#include<vector>
#include<algorithm>
using namespace std;

int main(){
    string t;
    cin >> t;
    int c=0,m=0;
    for(int i=0;i<t.size();i++){
        if(t[i]=='A'or'T'or'C'or'G'){
            c++;
        }
        else{
            if(c>m){
                m=c;
                c=0;
            }
        }
    }
    if(c>m) m=c;
    cout << m << endl;
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:13:18: error: unable to find character literal operator 'operator""or' with 'char' argument
   13 |         if(t[i]=='A'or'T'or'C'or'G'){
      |                  ^~~~~
a.cc:13:23: error: expected ')' before user-defined character literal
   13 |         if(t[i]=='A'or'T'or'C'or'G'){
      |           ~           ^~~~~
      |                       )
Language: C++

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

int main() {
  string S;
  cin>>S;
  S+='Z'
  int ans=0;
  
  for(int i=0;i<S.size();i++){
    int ans1=0;
    int j=i;
    while(S.at(j)=='A'||S.at(j)=='T'||S.at(j)=='G'||S.at(j)=='C'){
      ans1++;
      j++;
    }
    ans=max(ans,ans1);
  }
  cout<<ans<<endl;

}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:9: error: expected ';' before 'int'
    7 |   S+='Z'
      |         ^
      |         ;
    8 |   int ans=0;
      |   ~~~    
a.cc:17:5: error: 'ans' was not declared in this scope; did you mean 'ans1'?
   17 |     ans=max(ans,ans1);
      |     ^~~
      |     ans1
a.cc:19:9: error: 'ans' was not declared in this scope; did you mean 'abs'?
   19 |   cout<<ans<<endl;
      |         ^~~
      |         abs
Language: C++

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

int main() {
  string S;
  cin>>S;
  int ans=0;
  
  for(int i=0;i<S.size();i++){
    int ans1=0;
    int j=0;
    while(S.at(j)=='A'||S.at(j)=='T'||S.at(j)=='G'||S.at(j)=='C'){
      ans1++;
      j++
    }
    ans=max(ans,ans1)
  }
  cout<<ans<<endl;

}

Compiler output:
a.cc: In function 'int main()':
a.cc:14:10: error: expected ';' before '}' token
   14 |       j++
      |          ^
      |          ;
   15 |     }
      |     ~     
a.cc:16:22: error: expected ';' before '}' token
   16 |     ans=max(ans,ans1)
      |                      ^
      |                      ;
   17 |   }
      |   ~
Language: C++

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

int main(){
  string S;
  int l,i,count,max;
  count=0;
  cin >> S;
  l=S.size();
  for(i=0;i<l;i++){
    if(S.at(i)=='A'||S.at(i)=='C'||S.at(i)=='G'||S.at(i)=='T'){
      count++;
    }
    else if(count>max){
      max=count;
      count=0;
    }
    else{
      count=0;
   }
  if(count>max){
    max=count;
  }
    cout << max << endl;
   }

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

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

int main(){
  string S;
  int l,i,count,max;
  count=0;
  cin >> S;
  l=S.size();
  for(i=0;i<l;i++){
    if(S.at(i)=='A'||S.at(i)=='C'||S.at(i)=='G'||S.at(i)=='T'){
      count++;
    }
    else if(count>max){
      max=count;
      count=0;
    }
    else{
      count=0;
   }
  if(count>max){
    max=count;
  }
    cout << max << endl;
   }
      
  
  


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

#include <iostream>
#include <math.h>
#include <algorithm>
#include <string>
using namespace std;

int main(){
	int count=0,ans=0;
	char s[11];
	cin>>s;
	for(int i=0;i<strlen(s);i++)
	{
		if(s[i]=='T'||s[i]=='G'||s[i]=='C'||s[i]=='A')count++;
		else
		{
			ans=max(ans,count);
			count=0;
		}
	}
	cout<<ans;
	return 0;
	}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:23: error: 'strlen' was not declared in this scope
   11 |         for(int i=0;i<strlen(s);i++)
      |                       ^~~~~~
a.cc:4:1: note: 'strlen' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    3 | #include <algorithm>
  +++ |+#include <cstring>
    4 | #include <string>
Language: C++

#include <bits/stdc++.h> 
using namespace std;
 
int main(){
  string S;
  cin >> S;
  int cnt = 0;
  int max_cnt = 0;
  int size = S.size();
  
  for(int i=0; i<size; i++){
    if(S.at(i) == 'A' || S.at(i) == 'C' || S.at(i) == 'G' || S.at(i) == 'T'){
      cnt++;
    }else{
      cnt = 0;
    }
    if(cnt > max_cnt){
      max_cnt = cnt;
    }
  } 
  cout << length;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:21:11: error: 'length' was not declared in this scope
   21 |   cout << length;
      |           ^~~~~~
Language: Java

import java.util.*;
class Main{
	public static void main(String[] args){
    	Scanner scan = new Scanner(System.in);
      	String word = scan.next();
      	int ans = 0;
      	int subans =0;
      	int check =0;
      	for(int i=0;i<word.length;i++){
        	if(word.substring(i,i+1).equals("C") || word.substring(i,i+1).equals("G") || word.substring(i,i+1).equals("T") ||word.substring(i,i+1).equals("A")){
            	subans++;
            } else {
            	if(ans < subans){
                	ans = subans;
                }
              	subans = 0;
            }
        }
    }
}

Compiler output:
Main.java:9: error: cannot find symbol
      	for(int i=0;i<word.length;i++){
      	                  ^
  symbol:   variable length
  location: variable word of type String
1 error
Language: C++


#include <bits/stdc++.h>

#define FOR(i, m, n) for (int i = (m); i < (n); ++i)
#define REP(i, n) FOR(i, 0, n)
#define dump(x)  cerr << #x << " = " << (x) << endl
#define debug(x) cerr << #x << " = " << (x) << " (L" << __LINE__ << ")" << " " << __FILE__ << endl

using namespace std;

typedef long long LL;

template<typename T>
ostream& operator << (ostream& os, const vector<T>& vec) {
    os << "[ ";
    REP(i, vec.size()) {
        os << vec[i] << " ";
    }
    os << "]";

    return os;
}

bool check(const char &x) {
    return x != 'A' && x != 'C' && x != 'G' && x != 'T';
}

int main(){
    cin.tie(0);
    ios_base::sync_with_stdio(false);
    string S; cin >> S;

    int max = 0;
    int start, end;
    REP(i, S.size()) {
        if (check(S[i])) {
            continue;
        }

        start = i;
        end = i;
        while(end < S.size()) {
            if (check(S[++end])) break;
        }

        max = max(max, end - start);

        i = end + 1;
    }

    cout << max << endl;

}


Compiler output:
a.cc: In function 'int main()':
a.cc:46:18: error: 'max' cannot be used as a function
   46 |         max = max(max, end - start);
      |               ~~~^~~~~~~~~~~~~~~~~~
Language: C

#include<stdio.h>
#include<string.h>
int main(void){
  char s[11];
  int len, i;
  int cnt = 0;
  int kaisuu = 0;
  
  scanf("%s", s);
  len = strlen(s);
  
  for(i = 0; i < len; l++){
    if(s[i] == 'A' || s[i] == 'T' || s[i] == 'C' || s[i] == 'G'){
      kaisuu++;
    }
    else{
      if(cnt < kaisuu){
        cnt = kaisuu;
      }
      kaisuu = 0;
    }
  }
  printf("%d\n", cnt);
  return 0;
}

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

s = input()
ans=0
cnt=0
for i in s:
    if cnt>=ans:
        ans=cnt
    if i in ["A","T","C","G"]:
        cnt+=1
    else:
        cnt=0
if cnt>=ans:
    ans=cnt
print(ans)

Compiler output:
main.c:1:1: warning: data definition has no type or storage class
    1 | s = input()
      | ^
main.c:1:1: error: type defaults to 'int' in declaration of 's' [-Wimplicit-int]
main.c:1:5: error: implicit declaration of function 'input' [-Wimplicit-function-declaration]
    1 | s = input()
      |     ^~~~~
main.c:1:5: error: initializer element is not constant
main.c:2:1: error: expected ',' or ';' before 'ans'
    2 | ans=0
      | ^~~
Language: C++

#include <iostream>
#include <string>
using namespace std;
int main(void){
  string word;
  cin >> word;
  
  int n = word.length();
  
  int ans = 0;
  
  for(int i=0;i<n;i++){
    int l = 0;
    for(int j=i;j<n;j++){
      if(word[j] == 'A'||word[j] =='T'||word[j] == 'G'||word[j] == 'C'){
        if(j == i){
            l++;
          ans = max(ans,l);
        }
        else
          l++;
      }
      else
      	ans = max(ans,l);
      break;
    }
  
  cout << ans << endl;
  
  return 0;
}

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

#include <iostream>
#include <string>
using namespace std;
int main(void){
  string word;
  cin >> word;
  
  int n = word.length();
  
  int ans = 0;
  
  for(int i=0;i<n;i++){
    int l = 0;
    for(int j=i;j<n;j++){
      if(word[j] == 'A'||word[j] =='T'||word[j] == 'G'||word[j] == 'C'){
        if(j == i){
            l++;
          ans = max(ans,l);
        else
          l++;
        }
      }
      else
      	ans = max(ans,l);
      break;
    }
  }
  
  cout << ans << endl;
  
  return 0;
}
        
    

Compiler output:
a.cc: In function 'int main()':
a.cc:19:9: error: expected '}' before 'else'
   19 |         else
      |         ^~~~
a.cc:16:19: note: to match this '{'
   16 |         if(j == i){
      |                   ^
a.cc:23:7: error: 'else' without a previous 'if'
   23 |       else
      |       ^~~~
a.cc: At global scope:
a.cc:29:3: error: 'cout' does not name a type
   29 |   cout << ans << endl;
      |   ^~~~
a.cc:31:3: error: expected unqualified-id before 'return'
   31 |   return 0;
      |   ^~~~~~
a.cc:32:1: error: expected declaration before '}' token
   32 | }
      | ^
Language: C++

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

int main(){

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

  size_t len = s.length();
  for(int i=0;i<len;i++){
    if(s[i]!='A'&&s[i]!='T'&&s[i]!='G'&&s[i]!='C'){
      continue;
    }
    c[i]++;
    for(int j=i+1;j<len;j++){
       if(s[j]!='A'&&s[j]!='T'&&s[j]!='G'&&s[j]!='C'){
         break;
       }
       c[i]++;
    }
  }

  sort(c,c+10);
  cout << c[9] << endl;



}


Compiler output:
a.cc:1:1: error: 'include' does not name a type
    1 | include <bits/stdc++.h>
      | ^~~~~~~
a.cc: In function 'int main()':
a.cc:6:3: error: 'string' was not declared in this scope
    6 |   string s;
      |   ^~~~~~
a.cc:7:3: error: 'cin' was not declared in this scope
    7 |   cin >> s;
      |   ^~~
a.cc:7:10: error: 's' was not declared in this scope
    7 |   cin >> s;
      |          ^
a.cc:13:3: error: 'size_t' was not declared in this scope
   13 |   size_t len = s.length();
      |   ^~~~~~
a.cc:1:1: note: 'size_t' is defined in header '<cstddef>'; this is probably fixable by adding '#include <cstddef>'
  +++ |+#include <cstddef>
    1 | include <bits/stdc++.h>
a.cc:14:17: error: 'len' was not declared in this scope
   14 |   for(int i=0;i<len;i++){
      |                 ^~~
a.cc:27:3: error: 'sort' was not declared in this scope; did you mean 'short'?
   27 |   sort(c,c+10);
      |   ^~~~
      |   short
a.cc:28:3: error: 'cout' was not declared in this scope
   28 |   cout << c[9] << endl;
      |   ^~~~
a.cc:28:19: error: 'endl' was not declared in this scope
   28 |   cout << c[9] << endl;
      |                   ^~~~
Language: C++

include <algorithm>
#include <array>
#include <vector>
#include <iostream>
#include <fstream>
#include <string>
#include <cmath>
#include <functional>
#include <queue>
#include <random>
#include <map>
#include<iomanip>

//AtCoderC++.cpp

using namespace std;


#define rep(i,from,to) for(int i=from;i<to;i++)
#define ints(name,n) vector<int> name;name.resize(n)

template<typename T> void Show(vector<vector<T>> v, string delimiter = " ") {
	for (int i = 0; i < v.size(); i++) {
		for (int j = 0; j < v[i].size(); j++) {
			cout << v[i][j];
			if (j != v[i].size() - 1) {
				cout << delimiter;
			} else {
				cout << endl;
			}
		}
	}
}
template<typename T> void Show(vector<T> v, string delimiter = " ") {
	for (int i = 0; i < v.size(); i++) {
		cout << v[i];
		if (i != v.size() - 1) {
			cout << delimiter;
		} else {
			cout << endl;
		}
	}
}
template<typename T> vector<T> getUniform(T value, int n) {
	vector<vector<T>> ts;
	ts.resize(n);
	for (int i = 0; i < n; i++) {
		ts[i] = value;
	}
	return ts;
}
template<typename T> vector<vector<T>> getUniform(T value, int row, int col) {
	vector<vector<T>> ts;
	ts.resize(row);
	for (int i = 0; i < row; i++) {
		ts[i].resize(col);
		for (int j = 0; j < col; j++) {
			ts[i][j] = value;
		}
	}
	return ts;
}
bool All(vector<vector<bool>> ts) {
	int h = ts.size();
	int w = ts[0].size();
	rep(i, 0, h) {
		rep(j, 0, w) {
			if (!ts[i][j])return false;
		}
	}
	return true;
}

int main() {
	string code;
	cin >> code;
	auto ans = 0;
	string keys = "ATGC";
	for (size_t i = 0; i < code.length(); i++) {
		if (keys.find(code[i])) {
			auto count = 0;
			while (i < code.length() && keys.find(code[i])) {
				count++;
				i++;
			}
			ans = max(ans, count);
			i--;
		}
	}
	cout << ans << endl;
}

Compiler output:
a.cc:1:1: error: 'include' does not name a type
    1 | include <algorithm>
      | ^~~~~~~
In file included from /usr/include/c++/14/array:39,
                 from a.cc:2:
/usr/include/c++/14/initializer_list:51:15: error: 'size_t' does not name a type
   51 |       typedef size_t            size_type;
      |               ^~~~~~
/usr/include/c++/14/initializer_list:1:1: note: 'size_t' is defined in header '<cstddef>'; this is probably fixable by adding '#include <cstddef>'
  +++ |+#include <cstddef>
    1 | // std::initializer_list support -*- C++ -*-
/usr/include/c++/14/initializer_list:57:7: error: 'size_type' does not name a type
   57 |       size_type                 _M_len;
      |       ^~~~~~~~~
/usr/include/c++/14/initializer_list:60:54: error: 'size_type' has not been declared
   60 |       constexpr initializer_list(const_iterator __a, size_type __l)
      |                                                      ^~~~~~~~~
/usr/include/c++/14/initializer_list:68:17: error: 'size_type' does not name a type
   68 |       constexpr size_type
      |                 ^~~~~~~~~
/usr/include/c++/14/initializer_list:45:11: fatal error: definition of 'class std::initializer_list<_E>' does not match '#include <initializer_list>'
   45 |     class initializer_list
      |           ^~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include<iostream>
#include<string>
using namespace std;
 int main(void){

     string s;
     int count=0,max=0;
     int t = s.size();
     for(int i = 0; i < t;i++){
         if(s[i] == 'A'){
             count++;
         }else{
             count =0;
         ;
         if(s[i] == 'C'){
             count++;
         }else{
             count =0;
         
         if(s[i] == ''){
             count++;
         }else{
             count =0;
         ;
         if(s[i] == 'T'){
             count++;
         }else{
             count =0;
         }
         if(max < count)
         max = count;
     }

          for(int i = t; i > 0;i--){
         if(s[i] == 'A'){
             count++;
         }else{
             count =0;
         ;
         if(s[i] == 'C'){
             count++;
         }else{
             count =0;
         
         if(s[i] == ''){
             count++;
         }else{
             count =0;
         ;
         if(s[i] == 'T'){
             count++;
         }else{
             count =0;
         }
         if(max < count)
         max = count;
     }
 }

Compiler output:
a.cc:20:21: error: empty character constant
   20 |          if(s[i] == ''){
      |                     ^~
a.cc:45:21: error: empty character constant
   45 |          if(s[i] == ''){
      |                     ^~
a.cc: In function 'int main()':
a.cc:58:3: error: expected '}' at end of input
   58 |  }
      |   ^
a.cc:37:15: note: to match this '{'
   37 |          }else{
      |               ^
a.cc:58:3: error: expected '}' at end of input
   58 |  }
      |   ^
a.cc:34:36: note: to match this '{'
   34 |           for(int i = t; i > 0;i--){
      |                                    ^
a.cc:58:3: error: expected '}' at end of input
   58 |  }
      |   ^
a.cc:17:15: note: to match this '{'
   17 |          }else{
      |               ^
a.cc:58:3: error: expected '}' at end of input
   58 |  }
      |   ^
a.cc:12:15: note: to match this '{'
   12 |          }else{
      |               ^
a.cc:58:3: error: expected '}' at end of input
   58 |  }
      |   ^
a.cc:9:31: note: to match this '{'
    9 |      for(int i = 0; i < t;i++){
      |                               ^
a.cc:58:3: error: expected '}' at end of input
   58 |  }
      |   ^
a.cc:4:16: note: to match this '{'
    4 |  int main(void){
      |                ^
Language: C++

#include<isostrem>
#include<string>
using namespace std;
 int main(void){
     string s;
     cin >> s;
    int max=0,count = 0;

    for(int i = 0;i<10;i++){
        if(s[i] == 'A') count++;
        if(s[i] == 'C') count++;
        if(s[i] == 'G') count++;
        if(s[i] == 'T') count++;
        if(max < count) max = count;
        if(max == count) count = 0;
    }
 }

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

#include <iostream>
#include <list>

using namespace std;

int main() {
    string S; cin >> S;
    list<char> acgt = {'A', 'C', 'G', 'T'};
    int result = 0, temp_len = 0;
    for (int i=0; i < S.length(); i++) {
        if (find(acgt.begin(), acgt.end(), (char)S[i]) != acgt.end()) {
            temp_len++;
        } else {
            result = max(result,temp_len);
            temp_len = 0;
        }
    }
    result = max(result,temp_len);

    cout << result << endl; 
}       

Compiler output:
a.cc: In function 'int main()':
a.cc:11:17: error: no matching function for call to 'find(std::__cxx11::list<char>::iterator, std::__cxx11::list<char>::iterator, __gnu_cxx::__alloc_traits<std::allocator<char>, char>::value_type)'
   11 |         if (find(acgt.begin(), acgt.end(), (char)S[i]) != acgt.end()) {
      |             ~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/14/bits/locale_facets.h:48,
                 from /usr/include/c++/14/bits/basic_ios.h:37,
                 from /usr/include/c++/14/ios:46,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/streambuf_iterator.h:435:5: note: candidate: 'template<class _CharT2> typename __gnu_cxx::__enable_if<std::__is_char<_CharT2>::__value, std::istreambuf_iterator<_CharT> >::__type std::find(istreambuf_iterator<_CharT>, istreambuf_iterator<_CharT>, const _CharT2&)'
  435 |     find(istreambuf_iterator<_CharT> __first,
      |     ^~~~
/usr/include/c++/14/bits/streambuf_iterator.h:435:5: note:   template argument deduction/substitution failed:
a.cc:11:17: note:   'std::_List_iterator<char>' is not derived from 'std::istreambuf_iterator<_CharT>'
   11 |         if (find(acgt.begin(), acgt.end(), (char)S[i]) != acgt.end()) {
      |             ~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Language: C++

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

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

  	int count = 0;
  	int ans = 0;
  	for(int i=0; i<s.size(); i++){
    	if(s[i] == 'A' || s[i] == 'C' || s[i] == 'G' || s[i] == 'T'){
        	count++;
        }else{
        	ans = count > ans ? count : ans;
          	count = 0
        }
    }
  	cout << ans << endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:16:26: error: expected ';' before '}' token
   16 |                 count = 0
      |                          ^
      |                          ;
   17 |         }
      |         ~
Language: C++

S = str(input())
N = len(S)

ans = 0
for i in range(N):
    for j in range(i, N):
        if all('ACGT'.count(c) == 1 for c in S[i:j+1]):
            ans = max(ans, j-i+1)
print(ans)

Compiler output:
a.cc:7:16: warning: multi-character character constant [-Wmultichar]
    7 |         if all('ACGT'.count(c) == 1 for c in S[i:j+1]):
      |                ^~~~~~
a.cc:1:1: error: 'S' does not name a type
    1 | S = str(input())
      | ^
Language: C++

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

int main(){
  string S;
  cin >> S;
  int ans=0;
  int ACGT=0;
  for (int i=0;i<S.size();i++){
    if(S[i]=='A'or S[i]=='C'or S[i]=='G'or S[i]=='T'){
      ACGT++;
    }
    else{
      ans=max(AGCT,ans);
      ACGT=0;
    }
  }
  cout << ans << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:10:14: error: unable to find character literal operator 'operator""or' with 'char' argument
   10 |     if(S[i]=='A'or S[i]=='C'or S[i]=='G'or S[i]=='T'){
      |              ^~~~~
a.cc:10:19: error: expected ')' before 'S'
   10 |     if(S[i]=='A'or S[i]=='C'or S[i]=='G'or S[i]=='T'){
      |       ~           ^~
      |                   )
a.cc:14:15: error: 'AGCT' was not declared in this scope; did you mean 'ACGT'?
   14 |       ans=max(AGCT,ans);
      |               ^~~~
      |               ACGT
Language: Java

import java.util.Scanner;

class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String word = sc.next();

        int word_length = word.length();
        char wordAtindex = 'A';
        int index = 0;
        int max_sequental = 0;
        for (int i=0; i<word_length; i++)  {
            wordAtindex = word.charAt(i);

            if (wordAtindex=='A') {
                index++;
            } else if (wordAtindex=='T') {
                index++;
            } else if (wordAtindex=='C') {
                index++;
            } else if (wordAtindex=='G') {
                index++;
            } else {
                max_sequential = Math,max(index, max_sequential);
                index = 0;
            }
        }
        System.out.print(max_sequental);
    }
}

Compiler output:
Main.java:24: error: ';' expected
                max_sequential = Math,max(index, max_sequential);
                                     ^
1 error
Language: C

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

int main(void)
{
        char s[11];
        scanf("%s",s);
        int i,j=0,a=0,n=strlen(s);

        for(i=0;i<n;i++){
                a=0;
        while(s[i]=='A'||s[i]=='C'||s[i]=='G'||s[i]=='T'){
        a++;
        i++;
        }
        if (j<a) j=a;
        }
        print(%d,j);
        return 0;
        }

Compiler output:
main.c: In function 'main':
main.c:18:9: error: implicit declaration of function 'print'; did you mean 'printf'? [-Wimplicit-function-declaration]
   18 |         print(%d,j);
      |         ^~~~~
      |         printf
main.c:18:15: error: expected expression before '%' token
   18 |         print(%d,j);
      |               ^
Language: C

#include <stdio.h>
   
int main(void)
{
        char S[10];
        int i,j=0,t=0;
   
       scanf("%s",&S);   
        for(i=0;i<10;i++){
                if(S[i]=='A'|| S[i]=='C'|| S[i]=='G'|| S[i]=='T')
                        j++;
                if((S[i]!='A'&& S[i]!='C'&& S[i]!='G'&& S[i]!='T')){
                        if(j>t)t=j;
                        j=0;
                }
        }
    
        printf("%d\n",t);
    
        return 0;
}

~                                                                                                                                           
~                                                                                                                                           
~                                                                                                                                           
~                                                                                                                                           
~                        

Compiler output:
main.c:23:1: error: expected identifier or '(' before '~' token
   23 | ~
      | ^
Language: C++

#include <algorithm>
#include <array>
#include <vector>
#include <iostream>
#include <fstream>
#include <string>
#include <cmath>
#include <functional>
#include <queue>
#include <random>
#include<map>

//AtCoderC++.cpp

using namespace std;


#define rep(i,from,to) for(int i=from;i<to;i++)
#define ints(name,n) vector<int> name;name.resize(n)

template<typename T> void Show(vector<vector<T>> v, string delimiter = " ") {
	for (int i = 0; i < v.size(); i++) {
		for (int j = 0; j < v[i].size(); j++) {
			cout << v[i][j];
			if (j != v[i].size() - 1) {
				cout << delimiter;
			} else {
				cout << endl;
			}
		}
	}
}
template<typename T> void Show(vector<T> v, string delimiter = " ") {
	for (int i = 0; i < v.size(); i++) {
		cout << v[i];
		if (i != v.size() - 1) {
			cout << delimiter;
		} else {
			cout << endl;
		}
	}
}
template<typename T> vector<T> getUniform(T value, int n) {
	vector<vector<T>> ts;
	ts.resize(n);
	for (int i = 0; i < n; i++) {
		ts[i] = value;
	}
	return ts;
}
template<typename T> vector<vector<T>> getUniform(T value, int row, int col) {
	vector<vector<T>> ts;
	ts.resize(row);
	for (int i = 0; i < row; i++) {
		ts[i].resize(col);
		for (int j = 0; j < col; j++) {
			ts[i][j] = value;
		}
	}
	return ts;
}
bool All(vector<vector<bool>> ts) {
	int h = ts.size();
	int w = ts[0].size();
	rep(i, 0, h) {
		rep(j, 0, w) {
			if (!ts[i][j])return false;
		}
	}
	return true;
}

int main() {
	string code;
	cin >> code;
	int maxCount = 0;
	int begin = 0, end = 0;
	for (int i = 0; i < code.length() - 1; i++) {
		int count = 0;
		for (int j = i; j < code.length(); j++) {
			if (code[j] == 'A' || code[j] == 'T' || code[j] == 'G' || code[j] == 'C') count++;
			else {
				if (maxCount < count) {
					begin = i;
					end = j;
					maxCount = count;
				}
				break;
			}
		}
	}
	cout << j-i << endla;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:92:17: error: 'j' was not declared in this scope; did you mean 'jn'?
   92 |         cout << j-i << endla;
      |                 ^
      |                 jn
a.cc:92:19: error: 'i' was not declared in this scope
   92 |         cout << j-i << endla;
      |                   ^
a.cc:92:24: error: 'endla' was not declared in this scope; did you mean 'end'?
   92 |         cout << j-i << endla;
      |                        ^~~~~
      |                        end
Language: C++

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

int main(){
  string s;
  cin>>s;
  int cnt =0;
  int ans=0;
  for(int i=0;i<s.size();i++){
    if(s.at(i)=='A'||s.at(i)=='C'||s.at(i)=='G'||s.at(i)=='T'){
      cnt++;
    else
      cnt=0;
    if(cnt>ans)
      ans=cnt;
    }
  cout<<ans<<endl;
  }
      

Compiler output:
a.cc: In function 'int main()':
a.cc:12:5: error: expected '}' before 'else'
   12 |     else
      |     ^~~~
a.cc:10:63: note: to match this '{'
   10 |     if(s.at(i)=='A'||s.at(i)=='C'||s.at(i)=='G'||s.at(i)=='T'){
      |                                                               ^
Language: C++

#include<iostream>
#include<stdio.h>
#include<string.h>
#include<algorithm>
#include<vector>
#include<queue>
#include<map>
#include<set>

#define REP(i,n) for (int i = 0; (i) < (n); ++ (i))

using namespace std;

string S;
int kotae;
int f;
int main(){
  kotae = 0;
  cin >> S;
  REP(i,S.size()){
    for(int j=i,j<S.size(),j++){
      f = 0;
      for(int k=i,k<=j,k++){
        if(S[k] != 'A' ||  S[k] != 'C' || S[k] != 'G' || S[k] != 'T') f = 1;
      }
      if(f==0) kotae = max(kotae,j-i+1);
    }
  }
  cout << kotae << endl;
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:21:18: error: expected ';' before '<' token
   21 |     for(int j=i,j<S.size(),j++){
      |                  ^
      |                  ;
a.cc:21:18: error: expected primary-expression before '<' token
a.cc:21:31: error: expected ';' before ')' token
   21 |     for(int j=i,j<S.size(),j++){
      |                               ^
      |                               ;
a.cc:23:20: error: expected ';' before '<=' token
   23 |       for(int k=i,k<=j,k++){
      |                    ^~
      |                    ;
a.cc:23:20: error: expected primary-expression before '<=' token
   23 |       for(int k=i,k<=j,k++){
      |                    ^~
a.cc:23:27: error: expected ';' before ')' token
   23 |       for(int k=i,k<=j,k++){
      |                           ^
      |                           ;
Language: C++

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

int main(){
string S;
cin >> S;
int ans = 0;

// A, C, G, T
string T ="ACGT";

for(int i = 0; i < S.size(); i++){
	
	int now = 0;
	bool flag = false;
		
	for(int x =0; i < T.size(); x++){
	if(S.at(i) == T.at(x)) flag = true;
	}
	
	if(flag){
		now++;
		ans= max(ans, now);
	}else{
		continue;
	}
}
cout << ans << endl;

Compiler output:
a.cc: In function 'int main()':
a.cc:28:21: error: expected '}' at end of input
   28 | cout << ans << endl;
      |                     ^
a.cc:4:11: note: to match this '{'
    4 | int main(){
      |           ^
Language: C++

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

int main(){
string S;
cin >> S;
int ans=0;

// A, C, G, T
string T ="ACGT";

for(int i = 0; i < S.size(); i++){
	
	int now = 0;
	
	for(int x =0; i < T.size(); i++){
	bool flag = false;	
	if(string.at(i) == T.at(x)) flag = true;
	}
	
	if(flag){
		now++;
		ans= max(ans, now);
	}else{
		continue;
	}
}
cout << ans << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:18:18: error: expected unqualified-id before '.' token
   18 |         if(string.at(i) == T.at(x)) flag = true;
      |                  ^
a.cc:21:12: error: 'flag' was not declared in this scope
   21 |         if(flag){
      |            ^~~~
Language: C++

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

int main() {
	string S;
	cin >> S;

	int size = S.length();

	int ans = 0;
	int current = 0;
	for (int i = 0; i < size; i++) {
		if (S[i] == 'A' || S[i] == 'T' || S[i] == 'G' || S[i] == 'C') current++;
		else {
			if (ans < current) ans = current;

			if (i == N - 1) {
				if (ans < current) ans = current;
			}
			else {
				current = 0;
			}
		}
	}

	cout << ans;

	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:18:34: error: 'N' was not declared in this scope
   18 |                         if (i == N - 1) {
      |                                  ^
Language: C++

#include<iostream>
#include<string>
#include<stdio.h>
#include<cmath>
using namespace std;
int main(){
	string S;
	cin >> S;
	int count;
	for (int i = 0; i < S.size(); i++){
		if (S[i] == "A" || S[i] == "C" || S[i] == "G" || S[i] == "T"){
			count++;
		}
	}
	cout << count;
}​

Compiler output:
a.cc: In function 'int main()':
a.cc:11:26: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   11 |                 if (S[i] == "A" || S[i] == "C" || S[i] == "G" || S[i] == "T"){
a.cc:11:41: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   11 |                 if (S[i] == "A" || S[i] == "C" || S[i] == "G" || S[i] == "T"){
a.cc:11:56: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   11 |                 if (S[i] == "A" || S[i] == "C" || S[i] == "G" || S[i] == "T"){
a.cc:11:71: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   11 |                 if (S[i] == "A" || S[i] == "C" || S[i] == "G" || S[i] == "T"){
a.cc: At global scope:
a.cc:16:2: error: '\U0000200b' does not name a type
   16 | }​
      |
Language: C

#include<stdio.h>
  2 
  3 int main(void)
  4 {
  5         int n=0,s=0;
  6         char c;
  7 
  8         while(scanf("%c",&c)!=EOF)
  9         {
 10                 if((c=='A')||(c=='G')||(c=='T')||(c=='C')){
 11                         n=n+1;
 12                 }
 13                 else if(s<n){
 14                         s=n;
 15                         n=0;
 16                 }
 17         }
 18 
 19         printf("%d\n",s);
 20         return 0;
 21 }
 22 


Compiler output:
main.c:2:3: error: expected identifier or '(' before numeric constant
    2 |   2
      |   ^
main.c:22:2: error: expected identifier or '(' before numeric constant
   22 |  22
      |  ^~
Language: C++

#include <cstdio>

int main()
{
  char S[11];
  int length = 0;
  int ans = 0;
  
  if(scanf("%s", S) === EOF) {
    return -1
  }
  for (int i = 0; i < 11; i++) {
    if (S[i] === "A" ||
        S[i] === "C" ||
        S[i] === "G" ||
        S[i] === "T") {
      length++;
    } else {
      if (ans < length) {
        ans = length;
        length = 0;
      }
    }
  }
  print("%d", ans);
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:23: error: expected primary-expression before '=' token
    9 |   if(scanf("%s", S) === EOF) {
      |                       ^
a.cc:10:14: error: expected ';' before '}' token
   10 |     return -1
      |              ^
      |              ;
   11 |   }
      |   ~           
a.cc:13:16: error: expected primary-expression before '=' token
   13 |     if (S[i] === "A" ||
      |                ^
a.cc:14:16: error: expected primary-expression before '=' token
   14 |         S[i] === "C" ||
      |                ^
a.cc:15:16: error: expected primary-expression before '=' token
   15 |         S[i] === "G" ||
      |                ^
a.cc:16:16: error: expected primary-expression before '=' token
   16 |         S[i] === "T") {
      |                ^
a.cc:25:3: error: 'print' was not declared in this scope; did you mean 'printf'?
   25 |   print("%d", ans);
      |   ^~~~~
      |   printf
Language: C++

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

int main(){
	string a;
  	int count,tmp;
  	cin >> a;
  	tmp = 0;
  	for(int i = 0;i<a.size();i++){
    	if((a[i]=="A")||(a[i]=="C")||(a[i]=="G")||(a[i]=="T")){
        	count++;
          	if(tmp<count)tmp = count;
        }else{
        	count = 0;
        }
    }
	cout << tmp <<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:17: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   10 |         if((a[i]=="A")||(a[i]=="C")||(a[i]=="G")||(a[i]=="T")){
a.cc:10:30: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   10 |         if((a[i]=="A")||(a[i]=="C")||(a[i]=="G")||(a[i]=="T")){
a.cc:10:43: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   10 |         if((a[i]=="A")||(a[i]=="C")||(a[i]=="G")||(a[i]=="T")){
a.cc:10:56: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   10 |         if((a[i]=="A")||(a[i]=="C")||(a[i]=="G")||(a[i]=="T")){
Language: C++

#include <iostream>
 
using namespace std;
 
int main(){
    string s;
    int temp = 0, ans = 0;
    cin >> s;
    for(char p:s){
        if(p = "A"|| p = "G" || p = "C" || p = "T"||){
            temp++;
            ans = max(temp, ans);
        }else{
            temp = 0;
        }
    }
    cout << ans << endl;
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:10:53: error: expected primary-expression before ')' token
   10 |         if(p = "A"|| p = "G" || p = "C" || p = "T"||){
      |                                                     ^
Language: C++

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

int main(){
  string S;
  cin >> S;

  string T;
  T = "ATCG"
  int ans = 0;

  for(int i=0; i<S.size(); ++i){

    int now;
    for(int j=i; j<S.size(); ++j){
      bool ok = false;
      for(int k=0; k<T.size();++k){
        if("S[j]"="T[k]") ok = true;
      }

    if(ok){
      now++;
      ans = max(now,ans);
    } else{
      break;
    }
    }
  }

  cout << ans << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:10:13: error: expected ';' before 'int'
   10 |   T = "ATCG"
      |             ^
      |             ;
   11 |   int ans = 0;
      |   ~~~        
a.cc:19:18: error: assignment of read-only location '"S[j]"'
   19 |         if("S[j]"="T[k]") ok = true;
      |            ~~~~~~^~~~~~~
a.cc:24:7: error: 'ans' was not declared in this scope; did you mean 'abs'?
   24 |       ans = max(now,ans);
      |       ^~~
      |       abs
a.cc:31:11: error: 'ans' was not declared in this scope; did you mean 'abs'?
   31 |   cout << ans << endl;
      |           ^~~
      |           abs
Language: C++

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

int main(){
 
  string S;
  int N = S.size();
  int cnt=0, ans=0;
  
   for(i=0;i<N;i++){
     if(S[i] ='A'||'C'||'G'||'T' ){
      cnt ++;
     }
     else{
       ans=max(ans,cnt);
       cnt == 0;
     }
   }

 ans=max(ans,cnt);

  cout << ans << endl;
}


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

#include<bits/stdc++.h>
using namespace std;
int main()
{
    char str[20];
    int l,c=0,c2=0,i;
    gets(str);
    l=strlen(str);
    for(i=0;i<l;i++)
    {

       if(str[i]!='A' && str[i]!='C' && str[i]!='G' && str[i]!='T'){
        if(c>c2) c2=c;
       }
       else
       c++;

    }
    cout<<c2;
}


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(str);
      |     ^~~~
      |     getw
Language: C

#include <stdio.h>

int main(void){
  int ATC_COUNT[9] {0,0,0,0,0,0,0,0,0,0};
  char STRING[10];
  scanf("%s", string);
  for(int i=0; i<=9; i++){
    if(STRING[i] == 'A' || STRING[i] == 'G' || STRING[i] == 'C' || STRING[i] == 'T') {
      ATC_COUNT[i] = 1;
    }
  }
  return 0;
}
    
  

Compiler output:
main.c: In function 'main':
main.c:4:20: error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token
    4 |   int ATC_COUNT[9] {0,0,0,0,0,0,0,0,0,0};
      |                    ^
main.c:4:40: error: expected ';' before '}' token
    4 |   int ATC_COUNT[9] {0,0,0,0,0,0,0,0,0,0};
      |                                        ^
      |                                        ;
main.c:6:15: error: 'string' undeclared (first use in this function); did you mean 'stdin'?
    6 |   scanf("%s", string);
      |               ^~~~~~
      |               stdin
main.c:6:15: note: each undeclared identifier is reported only once for each function it appears in
main.c:9:7: error: 'ATC_COUNT' undeclared (first use in this function)
    9 |       ATC_COUNT[i] = 1;
      |       ^~~~~~~~~
Language: C++

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

int main(){
    char s;
    cin >> s;
    int n = (int)kan.size();

    int maxp = 0, ni = 0;
    for (int i = 0; i < N; i++) {
        if (kan[i] != 'A' && kan[i] != 'C' && kan[i] != 'G' && kan[i] != 'T'){
            ni = 0;
            continue;
        }
        maxp = max(maxp, ++ni)
    }


    cout << maxp << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:18: error: 'kan' was not declared in this scope; did you mean 'tan'?
    7 |     int n = (int)kan.size();
      |                  ^~~
      |                  tan
a.cc:10:25: error: 'N' was not declared in this scope
   10 |     for (int i = 0; i < N; i++) {
      |                         ^
a.cc:15:31: error: expected ';' before '}' token
   15 |         maxp = max(maxp, ++ni)
      |                               ^
      |                               ;
   16 |     }
      |     ~
Language: C++

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

int main() {
    const string ACGT = "ACGT";
    string S;
    cin >> S;

    string longestAcgt = "";
    size_t startPos = 0;
    while(startPos < S.length()) {
        if(startPos = S.find_first_of(ACGT, startPos) == -1)
            break;

        auto endPos = S.find_first_not_of(ACGT, startPos);
        auto ss = S.substr(startPos, endPos - startPos);
        if(ss.length() > longestAcgt.length())
            longestAcgt = ss;
        startPos = endPos + 1;
    }
    cout << longestAcgt.length << endl;
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:22:10: error: invalid use of non-static member function 'std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::length() const [with _CharT = char; _Traits = std::char_traits<char>; _Alloc = std::allocator<char>; size_type = long unsigned int]'
   22 |     cout << longestAcgt.length << endl;
      |     ~~~~~^~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/14/string:54,
                 from /usr/include/c++/14/bits/locale_classes.h:40,
                 from /usr/include/c++/14/bits/ios_base.h:41,
                 from /usr/include/c++/14/ios:44,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/basic_string.h:1083:7: note: declared here
 1083 |       length() const _GLIBCXX_NOEXCEPT
      |       ^~~~~~
Language: C++

S = input()

ans = 0
for i in range(len(S)):
    for j in range(i, len(S) + 1):
        s = set(S[i:j])
        if s <= set(["A", "C", "G", "T"]):
            ans = max(len(S[i:j]), ans)

print(ans)


Compiler output:
a.cc:1:1: error: 'S' does not name a type
    1 | S = input()
      | ^