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

#include <string>
#include <numeric>
using namespace std;
 
int main(){
 
    char b;
    cin >> b;
 
    if(b == 'A') cout << 'T' << endl;
    if(b == 'C') cout << 'G' << endl;
    if(b == 'G') cout << 'C' << endl;
    if(b == 'T') cout << 'A' << endl;
 
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:5: error: 'cin' was not declared in this scope
    8 |     cin >> b;
      |     ^~~
a.cc:3:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
    2 | #include <numeric>
  +++ |+#include <iostream>
    3 | using namespace std;
a.cc:10:18: error: 'cout' was not declared in this scope
   10 |     if(b == 'A') cout << 'T' << endl;
      |                  ^~~~
a.cc:10:18: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:10:33: error: 'endl' was not declared in this scope
   10 |     if(b == 'A') cout << 'T' << endl;
      |                                 ^~~~
a.cc:3:1: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
    2 | #include <numeric>
  +++ |+#include <ostream>
    3 | using namespace std;
a.cc:11:18: error: 'cout' was not declared in this scope
   11 |     if(b == 'C') cout << 'G' << endl;
      |                  ^~~~
a.cc:11:18: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:11:33: error: 'endl' was not declared in this scope
   11 |     if(b == 'C') cout << 'G' << endl;
      |                                 ^~~~
a.cc:11:33: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
a.cc:12:18: error: 'cout' was not declared in this scope
   12 |     if(b == 'G') cout << 'C' << endl;
      |                  ^~~~
a.cc:12:18: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:12:33: error: 'endl' was not declared in this scope
   12 |     if(b == 'G') cout << 'C' << endl;
      |                                 ^~~~
a.cc:12:33: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
a.cc:13:18: error: 'cout' was not declared in this scope
   13 |     if(b == 'T') cout << 'A' << endl;
      |                  ^~~~
a.cc:13:18: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:13:33: error: 'endl' was not declared in this scope
   13 |     if(b == 'T') cout << 'A' << endl;
      |                                 ^~~~
a.cc:13:33: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
Language: C++

include<iostream>
using namespace std;
int main(){
  char b;
  cin>>b;
  if(b=='A'){cout<<'T'<<endl;}
  else if(b=='T'){cout<<'A'<<endl;}
  else if(b=='C'){cout<<'G'<<endl;}
  else if(b=='G'){cout<<'C'<<endl;}
  return 0;
}

Compiler output:
a.cc:1:1: error: 'include' does not name a type
    1 | include<iostream>
      | ^~~~~~~
a.cc: In function 'int main()':
a.cc:5:3: error: 'cin' was not declared in this scope
    5 |   cin>>b;
      |   ^~~
a.cc:6:14: error: 'cout' was not declared in this scope
    6 |   if(b=='A'){cout<<'T'<<endl;}
      |              ^~~~
a.cc:6:25: error: 'endl' was not declared in this scope
    6 |   if(b=='A'){cout<<'T'<<endl;}
      |                         ^~~~
a.cc:7:19: error: 'cout' was not declared in this scope
    7 |   else if(b=='T'){cout<<'A'<<endl;}
      |                   ^~~~
a.cc:7:30: error: 'endl' was not declared in this scope
    7 |   else if(b=='T'){cout<<'A'<<endl;}
      |                              ^~~~
a.cc:8:19: error: 'cout' was not declared in this scope
    8 |   else if(b=='C'){cout<<'G'<<endl;}
      |                   ^~~~
a.cc:8:30: error: 'endl' was not declared in this scope
    8 |   else if(b=='C'){cout<<'G'<<endl;}
      |                              ^~~~
a.cc:9:19: error: 'cout' was not declared in this scope
    9 |   else if(b=='G'){cout<<'C'<<endl;}
      |                   ^~~~
a.cc:9:30: error: 'endl' was not declared in this scope
    9 |   else if(b=='G'){cout<<'C'<<endl;}
      |                              ^~~~
Language: C++

#include<iostream>
using namespace std;

int main()
{
  char b,c[128];
    c["A"]="G";
    c["T"]="C";
    c["G"]="A";
    c["C"]="T";
  
  cin>>b;
  
  cout<<c[(int)b]<<endl;
  
}
    
      

Compiler output:
a.cc: In function 'int main()':
a.cc:7:6: error: invalid types 'char [128][const char [2]]' for array subscript
    7 |     c["A"]="G";
      |      ^
a.cc:8:6: error: invalid types 'char [128][const char [2]]' for array subscript
    8 |     c["T"]="C";
      |      ^
a.cc:9:6: error: invalid types 'char [128][const char [2]]' for array subscript
    9 |     c["G"]="A";
      |      ^
a.cc:10:6: error: invalid types 'char [128][const char [2]]' for array subscript
   10 |     c["C"]="T";
      |      ^
Language: C++

#include<iostream>
using namespace std;

int main()
{
  char b,c[128];
    c["A"]="T";
    c["T"]="A";
    c["G"]="C";
    c["C"]="G";
  
  cin>>b;
  
  cout<<c[(int)b]<<endl;
  
}
    
      

Compiler output:
a.cc: In function 'int main()':
a.cc:7:6: error: invalid types 'char [128][const char [2]]' for array subscript
    7 |     c["A"]="T";
      |      ^
a.cc:8:6: error: invalid types 'char [128][const char [2]]' for array subscript
    8 |     c["T"]="A";
      |      ^
a.cc:9:6: error: invalid types 'char [128][const char [2]]' for array subscript
    9 |     c["G"]="C";
      |      ^
a.cc:10:6: error: invalid types 'char [128][const char [2]]' for array subscript
   10 |     c["C"]="G";
      |      ^
Language: C++

#include<iostream>
using namespace std;

int main()
{
  char b,c[];
    c["A"]="T";
    c["T"]="A";
    c["G"]="C";
    c["C"]="G";
  
  cin>>b;
  
  cout<<c[(int)b]<<endl;
  
}
    
      

Compiler output:
a.cc: In function 'int main()':
a.cc:6:10: error: storage size of 'c' isn't known
    6 |   char b,c[];
      |          ^
Language: C++

#include <iostream>
using namespace std;


int main() {
  char b;
  cin>>b;
  
  switch(b){
    case "A":
      cout<<"T"<<endl;
      break;
    case "C":
       cout<<"G"<<endl;
         break;
    case "T":
      cout<<"A"<<endl;
        break;
    case "G":
      cout<<"C"<<endl;
        break;
      
  }
  
  return 0;
}
  

Compiler output:
a.cc: In function 'int main()':
a.cc:10:10: error: conversion from 'const char*' to 'int' in a converted constant expression
   10 |     case "A":
      |          ^~~
a.cc:10:10: error: could not convert '"A"' from 'const char [2]' to 'int'
   10 |     case "A":
      |          ^~~
      |          |
      |          const char [2]
a.cc:13:10: error: conversion from 'const char*' to 'int' in a converted constant expression
   13 |     case "C":
      |          ^~~
a.cc:13:10: error: could not convert '"C"' from 'const char [2]' to 'int'
   13 |     case "C":
      |          ^~~
      |          |
      |          const char [2]
a.cc:16:10: error: conversion from 'const char*' to 'int' in a converted constant expression
   16 |     case "T":
      |          ^~~
a.cc:16:10: error: could not convert '"T"' from 'const char [2]' to 'int'
   16 |     case "T":
      |          ^~~
      |          |
      |          const char [2]
a.cc:19:10: error: conversion from 'const char*' to 'int' in a converted constant expression
   19 |     case "G":
      |          ^~~
a.cc:19:10: error: could not convert '"G"' from 'const char [2]' to 'int'
   19 |     case "G":
      |          ^~~
      |          |
      |          const char [2]
Language: C++

#include <iostream>
using namespace std;


int main() {
  char b;
  cin>>b;
  
  switch(b){
    case "A":
      cout<<"T"<<endl;
      break;
    case "C":
       cout<<"G"<<endl;
         break;
    case "T":
      cout<<"A"<<endl;
        break;
    case "G":
      cout<<"C"<<endl;
        break;
      
  }
  
  return 0;
}
  
   

Compiler output:
a.cc: In function 'int main()':
a.cc:10:10: error: conversion from 'const char*' to 'int' in a converted constant expression
   10 |     case "A":
      |          ^~~
a.cc:10:10: error: could not convert '"A"' from 'const char [2]' to 'int'
   10 |     case "A":
      |          ^~~
      |          |
      |          const char [2]
a.cc:13:10: error: conversion from 'const char*' to 'int' in a converted constant expression
   13 |     case "C":
      |          ^~~
a.cc:13:10: error: could not convert '"C"' from 'const char [2]' to 'int'
   13 |     case "C":
      |          ^~~
      |          |
      |          const char [2]
a.cc:16:10: error: conversion from 'const char*' to 'int' in a converted constant expression
   16 |     case "T":
      |          ^~~
a.cc:16:10: error: could not convert '"T"' from 'const char [2]' to 'int'
   16 |     case "T":
      |          ^~~
      |          |
      |          const char [2]
a.cc:19:10: error: conversion from 'const char*' to 'int' in a converted constant expression
   19 |     case "G":
      |          ^~~
a.cc:19:10: error: could not convert '"G"' from 'const char [2]' to 'int'
   19 |     case "G":
      |          ^~~
      |          |
      |          const char [2]
Language: C++

#include <iostream>
using namespace std;
int main() {
  char b;
  cin>>b;
  
  switch(b){
    case "A":
      cout<<"T"<<endl;
      break;
    case "C":
       cout<<"G"<<endl;
         break;
    case "T":
      cout<<"A"<<endl;
        break;
    case "G":
      cout<<"C"<<endl;
        break;
      
  }
  
  return 0;
}
  
   

Compiler output:
a.cc: In function 'int main()':
a.cc:8:10: error: conversion from 'const char*' to 'int' in a converted constant expression
    8 |     case "A":
      |          ^~~
a.cc:8:10: error: could not convert '"A"' from 'const char [2]' to 'int'
    8 |     case "A":
      |          ^~~
      |          |
      |          const char [2]
a.cc:11:10: error: conversion from 'const char*' to 'int' in a converted constant expression
   11 |     case "C":
      |          ^~~
a.cc:11:10: error: could not convert '"C"' from 'const char [2]' to 'int'
   11 |     case "C":
      |          ^~~
      |          |
      |          const char [2]
a.cc:14:10: error: conversion from 'const char*' to 'int' in a converted constant expression
   14 |     case "T":
      |          ^~~
a.cc:14:10: error: could not convert '"T"' from 'const char [2]' to 'int'
   14 |     case "T":
      |          ^~~
      |          |
      |          const char [2]
a.cc:17:10: error: conversion from 'const char*' to 'int' in a converted constant expression
   17 |     case "G":
      |          ^~~
a.cc:17:10: error: could not convert '"G"' from 'const char [2]' to 'int'
   17 |     case "G":
      |          ^~~
      |          |
      |          const char [2]
Language: C++

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

int main() {
int N;
cin >> N;
if (N == A)
cout << G;
if (N == G)
cout << A;
if (N==C)
cout << T;
if (N == T)
cout << C;
cout << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:10: error: 'A' was not declared in this scope
    7 | if (N == A)
      |          ^
a.cc:8:9: error: 'G' was not declared in this scope
    8 | cout << G;
      |         ^
a.cc:9:10: error: 'G' was not declared in this scope
    9 | if (N == G)
      |          ^
a.cc:10:9: error: 'A' was not declared in this scope
   10 | cout << A;
      |         ^
a.cc:11:8: error: 'C' was not declared in this scope
   11 | if (N==C)
      |        ^
a.cc:12:9: error: 'T' was not declared in this scope
   12 | cout << T;
      |         ^
a.cc:13:10: error: 'T' was not declared in this scope
   13 | if (N == T)
      |          ^
a.cc:14:9: error: 'C' was not declared in this scope
   14 | cout << C;
      |         ^
Language: C++

#include "solveA.h"

#include <iostream>

int main() {
    char b;
    std::cin >> b;

    char ans = ' ';
    switch (b){
        case 'A' :
            ans = 'T';
            break;
        case 'C' :
            ans = 'G';
            break;
        case 'G' :
            ans = 'C';
            break;
        case 'T' :
            ans = 'A';
            break;
        default:;
    }
    std::cout<< ans << std::endl;
}

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

#include <iostream>

void main() {
    char b;
    std::cin >> b;

    char ans = ' ';
    switch (b){
        case 'A' :
            ans = 'T';
            break;
        case 'C' :
            ans = 'G';
            break;
        case 'G' :
            ans = 'C';
            break;
        case 'T' :
            ans = 'A';
            break;
        default:;
    }
    std::cout<< ans << std::endl;
}

Compiler output:
a.cc:3:1: error: '::main' must return 'int'
    3 | void main() {
      | ^~~~
Language: C++

#include <iostream>
using namespace std;
int main() {
  char in;
  cin >> in;
  if (in == "A") {
    return 'T';
  } else if (in == "C") {
    return 'G';
  } else if (in == "G") {
    return 'C';
  } else if (in == "T") {    
    return 'A';
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:10: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    6 |   if (in == "A") {
      |       ~~~^~~~~~
a.cc:8:17: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    8 |   } else if (in == "C") {
      |              ~~~^~~~~~
a.cc:10:17: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   10 |   } else if (in == "G") {
      |              ~~~^~~~~~
a.cc:12:17: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   12 |   } else if (in == "T") {
      |              ~~~^~~~~~
Language: C++

#include<iostream>
using namespace std;

int main(){
  char b;
  cin >> b;
  switch(b){
      case 'A'
        cout << 'T';
      	break;
      case 'T'
        cout << 'A';
      	break;
      case 'C'
        cout << 'G';
      	break;
      case 'G'
        cout << 'C';
      	break;
  }
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:15: error: expected ':' before 'cout'
    8 |       case 'A'
      |               ^
      |               :
    9 |         cout << 'T';
      |         ~~~~   
a.cc:11:15: error: expected ':' before 'cout'
   11 |       case 'T'
      |               ^
      |               :
   12 |         cout << 'A';
      |         ~~~~   
a.cc:14:15: error: expected ':' before 'cout'
   14 |       case 'C'
      |               ^
      |               :
   15 |         cout << 'G';
      |         ~~~~   
a.cc:17:15: error: expected ':' before 'cout'
   17 |       case 'G'
      |               ^
      |               :
   18 |         cout << 'C';
      |         ~~~~
Language: C++

#include <iostream>
 
int main(void)
{
  char characters[4] = {'A', 'C', 'G', 'T'};
  char input;
  
  cin >> input;
  for(int i=0; i<4; i++){
    if(input == characters[i]){
      cout << characters[3-i];
      break;
    }
  }
  
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    8 |   cin >> input;
      |   ^~~
      |   std::cin
In file included from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:11:7: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   11 |       cout << characters[3-i];
      |       ^~~~
      |       std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
Language: C++

#include <iostream>

int main(void)
{
  char characters[4] = {'A', 'C', 'G', 'T'};
  char input;
  
  cin >> input;
  for(int i=0; i<4; i++){
    if(input == characters[i]){
      cout << characters[3-i];
      break;
    }
  }
  
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    8 |   cin >> input;
      |   ^~~
      |   std::cin
In file included from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:11:7: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   11 |       cout << characters[3-i];
      |       ^~~~
      |       std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
Language: C++

include <iostream>

using namespace std;

int main(){
  char c;
  cin >> c;
  if(c == 'A') cout << "T" << endl;
  if(c == 'T') cout << "A" << endl;
  if(c == 'G') cout << "C" << endl;
  if(c == 'C') cout << "G" << endl;
  return 0;
}

Compiler output:
a.cc:1:1: error: 'include' does not name a type
    1 | include <iostream>
      | ^~~~~~~
a.cc: In function 'int main()':
a.cc:7:3: error: 'cin' was not declared in this scope
    7 |   cin >> c;
      |   ^~~
a.cc:8:16: error: 'cout' was not declared in this scope
    8 |   if(c == 'A') cout << "T" << endl;
      |                ^~~~
a.cc:8:31: error: 'endl' was not declared in this scope
    8 |   if(c == 'A') cout << "T" << endl;
      |                               ^~~~
a.cc:9:16: error: 'cout' was not declared in this scope
    9 |   if(c == 'T') cout << "A" << endl;
      |                ^~~~
a.cc:9:31: error: 'endl' was not declared in this scope
    9 |   if(c == 'T') cout << "A" << endl;
      |                               ^~~~
a.cc:10:16: error: 'cout' was not declared in this scope
   10 |   if(c == 'G') cout << "C" << endl;
      |                ^~~~
a.cc:10:31: error: 'endl' was not declared in this scope
   10 |   if(c == 'G') cout << "C" << endl;
      |                               ^~~~
a.cc:11:16: error: 'cout' was not declared in this scope
   11 |   if(c == 'C') cout << "G" << endl;
      |                ^~~~
a.cc:11:31: error: 'endl' was not declared in this scope
   11 |   if(c == 'C') cout << "G" << endl;
      |                               ^~~~
Language: C

#include <stdio.h>

int main(void){

    char base;
    scanf("%c", &base);

    if (base == 'A'){
        printf("T");
    } else if (base == 'T'){
        printf("A");
    } else if (base == 'G'){
        pritnf("C");
    } else {
        printf("G");
    }

    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:13:9: error: implicit declaration of function 'pritnf'; did you mean 'printf'? [-Wimplicit-function-declaration]
   13 |         pritnf("C");
      |         ^~~~~~
      |         printf
Language: Java

import java.util.Scanner;
public class HelloWorld{

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		Scanner sc = new Scanner(System.in);
		String line = sc.nextLine();
		
		if(line.equals("A")) {
			System.out.println("T");
		}else if(line.equals("T")){
			System.out.println("A");
		}else if(line.equals("C")){
			System.out.println("G");
		}else if(line.equals("G")){
			System.out.println("C");
		}
		
	}

}


Compiler output:
Main.java:2: error: class HelloWorld is public, should be declared in a file named HelloWorld.java
public class HelloWorld{
       ^
1 error
Language: Java

public class Main{

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		Scanner sc = new Scanner(System.in);
		String line = sc.nextLine();
		
		if(line.equals("A")) {
			System.out.println("T");
		}else if(line.equals("T")){
			System.out.println("A");
		}else if(line.equals("C")){
			System.out.println("G");
		}else if(line.equals("G")){
			System.out.println("C");
		}
		
	}

}

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

package sample;

import java.util.Scanner;
public class main{

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		Scanner sc = new Scanner(System.in);
		int a= sc.nextInt();
		String line = sc.nextLine();
		
		if(line == "A") {
			System.out.println("T");
		}else if(line == "T"){
			System.out.println("A");
		}else if(line == "C"){
			System.out.println("G");
		}else if(line == "T"){
			System.out.println("A");
		}}else if(line == "G"){
			System.out.println("C");
		}
		
	}

}

Compiler output:
Main.java:20: error: illegal start of type
		}}else if(line == "G"){
		  ^
Main.java:20: error: <identifier> expected
		}}else if(line == "G"){
		              ^
Main.java:26: error: class, interface, enum, or record expected
}
^
3 errors
Language: C++

#include<bits/stdc++.h>
using namespace std;
 
int main{
char x=b;
    if(b==A){
  cout << 'T' << endl;
  }
    if(b==T){
  cout << 'A' << endl;
  }  if(b==G){
  cout << 'C' << endl;
  }  if(b==C){
  cout << 'G' << endl;
  }
}


Compiler output:
a.cc:4:5: error: cannot declare '::main' to be a global variable
    4 | int main{
      |     ^~~~
a.cc:5:1: error: expected primary-expression before 'char'
    5 | char x=b;
      | ^~~~
a.cc:5:1: error: expected '}' before 'char'
a.cc:4:9: note: to match this '{'
    4 | int main{
      |         ^
a.cc:6:5: error: expected unqualified-id before 'if'
    6 |     if(b==A){
      |     ^~
a.cc:9:5: error: expected unqualified-id before 'if'
    9 |     if(b==T){
      |     ^~
a.cc:11:6: error: expected unqualified-id before 'if'
   11 |   }  if(b==G){
      |      ^~
a.cc:13:6: error: expected unqualified-id before 'if'
   13 |   }  if(b==C){
      |      ^~
a.cc:16:1: error: expected declaration before '}' token
   16 | }
      | ^
Language: C++

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

int main{
char x=b;
    if(b==A){
  cout << 'T' << endl;
  }
    if(b==T){
  cout << 'A' << endl;
  }  if(b==G){
  cout << 'C' << endl;
  }  if(b==G){
  cout << 'C' << endl;
  }
}

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

import java.util.Scanner

public static void main(String[] args) {
  Scanner scan = new Scanner(System.in);
  String input = scan.nextLine();
  scan.close();
  
  if (input.equals("A")) {
  	System.out.println("T");
  } else if (input.equals("T")) {
  	System.out.println("A");
  } else if (input.equals("C")) {
  	System.out.println("G");
  } else {
  	System.out.println("C");
  }
}

Compiler output:
Main.java:1: error: ';' expected
import java.util.Scanner
                        ^
Main.java:3: error: unnamed classes are a preview feature and are disabled by default.
public static void main(String[] args) {
              ^
  (use --enable-preview to enable unnamed classes)
2 errors
Language: C++

#include<iostream>
int main(){
  char a;
  cin>>a;
  if(a=='A')
    a='T';
  else if(a=='T')
    a='A';
  else if(a=='G')
    a='C';
  else
    a='G';
  cout<<a<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:4:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    4 |   cin>>a;
      |   ^~~
      |   std::cin
In file included from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:13:3: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   13 |   cout<<a<<endl;
      |   ^~~~
      |   std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:13:12: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   13 |   cout<<a<<endl;
      |            ^~~~
      |            std::endl
In file included from /usr/include/c++/14/iostream:41:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: C++

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

int main() {
	char b; cin >> b;
	if (b == 'A') cout << 'T' << endl;
	e se if (b == 'T') cout << 'A' << endl;
	else if (b == 'G') cout << 'C' << endl;
	else if (b == 'C') cout << 'G' << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:9: error: 'e' was not declared in this scope
    7 |         e se if (b == 'T') cout << 'A' << endl;
      |         ^
a.cc:8:9: error: 'else' without a previous 'if'
    8 |         else if (b == 'G') cout << 'C' << endl;
      |         ^~~~
Language: C++

#include <iostream>
#include <unordered_map>
using std::unordered_map;
using std::cout;
using std::endl;
int main() {
  unordered_map<char,char> m = {
    {'A','T'},{'T','A'},{'C','G'},{'G','C'}
  };
  char input;
  cin >> input;
  cout << m[input] << endl;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
   11 |   cin >> input;
      |   ^~~
      |   std::cin
In file included from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
Language: C++

#include <iostream>
int main() {
  unordered_map<char,char> map={
    	{'A','T'},{'T','A'},{'G','C'},{'C','G'}
  };
  char input;
  cin >> input;
  cout << map[input] << endl;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:3:3: error: 'unordered_map' was not declared in this scope
    3 |   unordered_map<char,char> map={
      |   ^~~~~~~~~~~~~
a.cc:3:17: error: expected primary-expression before 'char'
    3 |   unordered_map<char,char> map={
      |                 ^~~~
a.cc:7:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    7 |   cin >> input;
      |   ^~~
      |   std::cin
In file included from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:8:3: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    8 |   cout << map[input] << endl;
      |   ^~~~
      |   std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:8:11: error: 'map' was not declared in this scope
    8 |   cout << map[input] << endl;
      |           ^~~
a.cc:8:25: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    8 |   cout << map[input] << endl;
      |                         ^~~~
      |                         std::endl
In file included from /usr/include/c++/14/iostream:41:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: Java

import java.util.Scanner;

public class DoubleHelix {

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Scanner sc = new Scanner(System.in);
		String Base = sc.nextLine();
		switch(Base) {
			case "A":
				System.out.println("T");
				break;
			case "T":
				System.out.println("A");
				break;
			case "C":
				System.out.println("G");
				break;
			default:
				System.out.println("C");
		}
	}
}


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

#include<stdio.h>
int main(void){
  char b[];
  scanf("%c",&b[]);
  if(b[]=="A"){
    printf("T");
  }
  else if(b[]=="T"){
    printf("A");
  }
  else if(b[]=="G"){
    printf("C");
  }
  else if(b[]=="C"){
    printf("G");
  }
return 0;
}

Compiler output:
main.c: In function 'main':
main.c:3:8: error: array size missing in 'b'
    3 |   char b[];
      |        ^
main.c:4:17: error: expected expression before ']' token
    4 |   scanf("%c",&b[]);
      |                 ^
main.c:5:8: error: expected expression before ']' token
    5 |   if(b[]=="A"){
      |        ^
main.c:8:13: error: expected expression before ']' token
    8 |   else if(b[]=="T"){
      |             ^
main.c:11:13: error: expected expression before ']' token
   11 |   else if(b[]=="G"){
      |             ^
main.c:14:13: error: expected expression before ']' token
   14 |   else if(b[]=="C"){
      |             ^
Language: C

#include<stdio.h>
int main(void){
  char s[];
  scanf("%s",s[]);
  if(s[]=="A"){
    printf("T");
  }
  else if(s[]=="T"){
    printf("A");
  }
  else if(s[]=="G"){
    printf("C");
  }
  else if(s[]=="C"){
    printf("G");
  }
return 0;
}

Compiler output:
main.c: In function 'main':
main.c:3:8: error: array size missing in 's'
    3 |   char s[];
      |        ^
main.c:4:16: error: expected expression before ']' token
    4 |   scanf("%s",s[]);
      |                ^
main.c:5:8: error: expected expression before ']' token
    5 |   if(s[]=="A"){
      |        ^
main.c:8:13: error: expected expression before ']' token
    8 |   else if(s[]=="T"){
      |             ^
main.c:11:13: error: expected expression before ']' token
   11 |   else if(s[]=="G"){
      |             ^
main.c:14:13: error: expected expression before ']' token
   14 |   else if(s[]=="C"){
      |             ^
Language: C

#include<stdio.h>
int main(void){
  char s;
  scanf("%s",&s);
  if(s==A){
    printf("T");
  }
  else if(s==T){
    printf("A");
  }
  else if(s==G){
    printf("C");
  }
  else if(s==C){
    printf("G");
  }
return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:9: error: 'A' undeclared (first use in this function)
    5 |   if(s==A){
      |         ^
main.c:5:9: note: each undeclared identifier is reported only once for each function it appears in
main.c:8:14: error: 'T' undeclared (first use in this function)
    8 |   else if(s==T){
      |              ^
main.c:11:14: error: 'G' undeclared (first use in this function)
   11 |   else if(s==G){
      |              ^
main.c:14:14: error: 'C' undeclared (first use in this function)
   14 |   else if(s==C){
      |              ^
Language: C

#include <stdio.h>

int main() {
	char b;
	scanf_s("%c", &b);
	if (b == 'A')
		b = 'T';
	else if (b == 'T')
		b = 'A';
	else if (b == 'C')
		b = 'G';
	else
		b = 'C';
	printf("%c", b);
}

Compiler output:
main.c: In function 'main':
main.c:5:9: error: implicit declaration of function 'scanf_s'; did you mean 'scanf'? [-Wimplicit-function-declaration]
    5 |         scanf_s("%c", &b);
      |         ^~~~~~~
      |         scanf
Language: C++

#include <stdio.h>

int main() {
	char b;
	scanf_s("%c", &b);
	if (b == 'A')
		b = 'T';
	else if (b == 'T')
		b = 'A';
	else if (b == 'C')
		b = 'G';
	else
		b = 'C';
	printf("%c\n", b);
}

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

#include <stdio.h>

int main(){
	char b;
	scanf_s("%c", &b);
	if (b == 'A') printf("T");
	if (b == 'T') printf("A");
	if (b == 'C') printf("G");
	if (b == 'G') printf("C");
}

Compiler output:
main.c: In function 'main':
main.c:5:9: error: implicit declaration of function 'scanf_s'; did you mean 'scanf'? [-Wimplicit-function-declaration]
    5 |         scanf_s("%c", &b);
      |         ^~~~~~~
      |         scanf
Language: C++

#incude<iostream>
using namespace std;
int nain(){
  String "A","G","C","T","b";
  cin >> "A" >> "G" >> "C">> "T" >> "b";
  if("b" == "A"){cout << "T" << endl;}
  else("b" == "G");{cout << "C" << endl;}}

Compiler output:
a.cc:1:2: error: invalid preprocessing directive #incude; did you mean #include?
    1 | #incude<iostream>
      |  ^~~~~~
      |  include
a.cc: In function 'int nain()':
a.cc:4:3: error: 'String' was not declared in this scope
    4 |   String "A","G","C","T","b";
      |   ^~~~~~
a.cc:5:3: error: 'cin' was not declared in this scope
    5 |   cin >> "A" >> "G" >> "C">> "T" >> "b";
      |   ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
  +++ |+#include <iostream>
    1 | #incude<iostream>
a.cc:6:18: error: 'cout' was not declared in this scope
    6 |   if("b" == "A"){cout << "T" << endl;}
      |                  ^~~~
a.cc:6:18: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:6:33: error: 'endl' was not declared in this scope
    6 |   if("b" == "A"){cout << "T" << endl;}
      |                                 ^~~~
a.cc:1:1: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
  +++ |+#include <ostream>
    1 | #incude<iostream>
a.cc:7:21: error: 'cout' was not declared in this scope
    7 |   else("b" == "G");{cout << "C" << endl;}}
      |                     ^~~~
a.cc:7:21: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:7:36: error: 'endl' was not declared in this scope
    7 |   else("b" == "G");{cout << "C" << endl;}}
      |                                    ^~~~
a.cc:7:36: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
a.cc:7:42: warning: no return statement in function returning non-void [-Wreturn-type]
    7 |   else("b" == "G");{cout << "C" << endl;}}
      |                                          ^
Language: Java

import java.util.Scanner;
public class maiｎ {

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

		 String b = scan.next();

		 if(b == "A") {
			 System.out.println("T");
		 }else if( b == "T"){
			 System.out.println("A");
		 }else if( b == "G"){
			 System.out.println("C");
		 }else if(b == "C") {
			 System.out.println("G");
		 }

	}

}


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

#include <stdio.h>
int main(int argc, char *argv[]){
  switch(argv[1]){
    case "A":
      printf("T");break;
    case "T":
      printf("A");break;
    case "C":
      printf("G");break;
    case "G":
      printf("C");break;
  }
}

Compiler output:
a.cc: In function 'int main(int, char**)':
a.cc:3:16: error: switch quantity not an integer
    3 |   switch(argv[1]){
      |          ~~~~~~^
Language: C++

int main(int argc, char *argv[]){
  switch(argv[1]){
    case "A":
      printf("T");break;
    case "T":
      printf("A");break;
    case "C":
      printf("G");break;
    case "G":
      printf("C");break;
  }
}

Compiler output:
a.cc: In function 'int main(int, char**)':
a.cc:2:16: error: switch quantity not an integer
    2 |   switch(argv[1]){
      |          ~~~~~~^
a.cc:4:7: error: 'printf' was not declared in this scope
    4 |       printf("T");break;
      |       ^~~~~~
a.cc:1:1: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
  +++ |+#include <cstdio>
    1 | int main(int argc, char *argv[]){
Language: C++

#include <stdio.h>

int main(int argc, char *argv[]){
  switch(argv[1]){
    case 'A':
      printf("T");break;
    case 'T':
      printf("A");break;
    case 'C':
      printf("G");break;
    case 'G':
      printf("C");break;
  }
}

Compiler output:
a.cc: In function 'int main(int, char**)':
a.cc:4:16: error: switch quantity not an integer
    4 |   switch(argv[1]){
      |          ~~~~~~^
Language: C++

b = input()
if b == 'A':
    print('T')
elif b == 'T':
    print('A')
elif b == 'C':
    print('G')
elif b == 'G':
    print('C')

Compiler output:
a.cc:1:1: error: 'b' does not name a type
    1 | b = input()
      | ^
Language: C++

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

int main(){
  char b,
  cin >> b;
  switch (b){
    case 'A':
      cout << "T" << endl;
      break;
    case 'T':
      cout << "A" << endl;
      break;
    case 'C':
      cout << "G" << endl;
      break;
    case 'G':
      cout << "C" << endl;
      break;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:7: error: expected initializer before '>>' token
    7 |   cin >> b;
      |       ^~
Language: C

int main(){
  char a,b;
  scanf("%c",&a);
  if(a=='A'){
    b='T';
  }
  else if(a=='T'){
    b='A';
  }
  else if(a=='C'){
    b='G';
  }
  else{
    b='C'
  }
  printf("%C",b);
}

Compiler output:
main.c: In function 'main':
main.c:3:3: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
    3 |   scanf("%c",&a);
      |   ^~~~~
main.c:1:1: note: include '<stdio.h>' or provide a declaration of 'scanf'
  +++ |+#include <stdio.h>
    1 | int main(){
main.c:3:3: warning: incompatible implicit declaration of built-in function 'scanf' [-Wbuiltin-declaration-mismatch]
    3 |   scanf("%c",&a);
      |   ^~~~~
main.c:3:3: note: include '<stdio.h>' or provide a declaration of 'scanf'
main.c:14:10: error: expected ';' before '}' token
   14 |     b='C'
      |          ^
      |          ;
   15 |   }
      |   ~       
main.c:16:3: error: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
   16 |   printf("%C",b);
      |   ^~~~~~
main.c:16:3: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:16:3: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
main.c:16:3: note: include '<stdio.h>' or provide a declaration of 'printf'
Language: C

#include<stdio.h>
int main(void){char a;scanf("%s",&a);switch(a){case A:printf("T\n");break;case T:printf("A\n");break;case G:printf("C\n");break;case C:printf("G\n");break;}return 0;}

Compiler output:
main.c: In function 'main':
main.c:2:53: error: 'A' undeclared (first use in this function)
    2 | int main(void){char a;scanf("%s",&a);switch(a){case A:printf("T\n");break;case T:printf("A\n");break;case G:printf("C\n");break;case C:printf("G\n");break;}return 0;}
      |                                                     ^
main.c:2:53: note: each undeclared identifier is reported only once for each function it appears in
main.c:2:80: error: 'T' undeclared (first use in this function)
    2 | int main(void){char a;scanf("%s",&a);switch(a){case A:printf("T\n");break;case T:printf("A\n");break;case G:printf("C\n");break;case C:printf("G\n");break;}return 0;}
      |                                                                                ^
main.c:2:107: error: 'G' undeclared (first use in this function)
    2 | int main(void){char a;scanf("%s",&a);switch(a){case A:printf("T\n");break;case T:printf("A\n");break;case G:printf("C\n");break;case C:printf("G\n");break;}return 0;}
      |                                                                                                           ^
main.c:2:134: error: 'C' undeclared (first use in this function)
    2 | int main(void){char a;scanf("%s",&a);switch(a){case A:printf("T\n");break;case T:printf("A\n");break;case G:printf("C\n");break;case C:printf("G\n");break;}return 0;}
      |                                                                                                                                      ^
Language: C++

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

int main(){
  char b;
  cin>>b;
  if(b=="A")cout<<"T"<<endl;
  if(b=="T")cout<<"A"<<endl;
  if(b=="G")cout<<"C"<<endl;
  if(b=="C")cout<<"G"<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:7: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    7 |   if(b=="A")cout<<"T"<<endl;
      |      ~^~~~~
a.cc:8:7: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    8 |   if(b=="T")cout<<"A"<<endl;
      |      ~^~~~~
a.cc:9:7: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    9 |   if(b=="G")cout<<"C"<<endl;
      |      ~^~~~~
a.cc:10:7: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   10 |   if(b=="C")cout<<"G"<<endl;
      |      ~^~~~~
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: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();

        if (word.equals("A")) {
            System.out.print("T");
        } else if (word.equals("A")) {
            System.out.print("A");
        } else if (word.equals("C")) {
            System.out.print("G");
        } else if (word.equals("G")) {
            System.out.print("C");
    }
}

Compiler output:
Main.java:17: error: reached end of file while parsing
}
 ^
1 error
Language: Java

import java.util.Scanner;

class Main {
    public static void main(String[] args) {
    	Scanner sc = new Scanner(System.in);
        String input = sc.next();
      	String answer;
      
        switch(input) {
          case "A":
            answer = "T";
            break;
          case "T":
            answer = "A";
            break;
          case "C":
            answer = "G";
            break;
          case "G":
            answer = "C";
            break;
        }
      
        System.out.print(answer);
    }
}

Compiler output:
Main.java:24: error: variable answer might not have been initialized
        System.out.print(answer);
                         ^
1 error
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
	char s;cin>>s;
	if(s=='A'){
		cout<<"T"<<endl;
	}else(s=='T'){
		cout<<"A"<<endl;
	}else(s=='G'){
		cout<<"C"<<endl;
	}else{
		cout<<"G"<<endl;
	}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:22: error: expected ';' before '{' token
    7 |         }else(s=='T'){
      |                      ^
      |                      ;
a.cc:9:10: error: 'else' without a previous 'if'
    9 |         }else(s=='G'){
      |          ^~~~
a.cc:9:22: error: expected ';' before '{' token
    9 |         }else(s=='G'){
      |                      ^
      |                      ;
a.cc:11:10: error: 'else' without a previous 'if'
   11 |         }else{
      |          ^~~~
Language: C

include<stdio.h>

int main(void)
{
    char a;

    scanf("%c",&a);
         if (a=='A') printf("T\n");
    else if (a=='C') printf("G\n");
    else if (a=='G') printf("C\n");
    else if (a=='T') printf("A\n");
    return 0;
}


Compiler output:
main.c:1:8: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
    1 | include<stdio.h>
      |        ^
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:31: error: expected ';' before ')' token
   21 |     for(int j=i;j<S.size(),j++){
      |                               ^
      |                               ;
a.cc:23:27: error: expected ';' before ')' token
   23 |       for(int k=i;k<=j,k++){
      |                           ^
      |                           ;
Language: C++

#include<iostream>
using namespace std;
int main(void){
std::string str1 = "A";
std::string str2 = "C";
std::string str3 = "G";
std::string str4 = "T";
  String b; b=str1, str2, str3, str4;
Case1:(cin >> str1);{
  cout << str4 << endl;}
  Case2:(cin >> str2);{
    cout << str3 << endl;}
  Case3:(cin >> str3);{
    cout << str2 << endl;}
  Case4:(cin >> str4);{
    cout << str1 << endl;}
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:3: error: 'String' was not declared in this scope
    8 |   String b; b=str1, str2, str3, str4;
      |   ^~~~~~
a.cc:8:13: error: 'b' was not declared in this scope
    8 |   String b; b=str1, str2, str3, str4;
      |             ^
Language: C++

#include<iostream>
using namespace std;
int main(void){
std::string str1 = "A";
std::string str2 = "C";
std::string str3 = "G";
std::string str4 = "T";
Case1:(cin >> str1){
  cout << str4 << endl;}
  Case2:(cin >> str2);{
    cout << str3 << endl;}
  Case3:(cin >> str3);{
    cout << str2 << endl;}
  Case4:(cin >> str4);{
    cout << str1 << endl;}
  break;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:20: error: expected ';' before '{' token
    8 | Case1:(cin >> str1){
      |                    ^
      |                    ;
a.cc:16:3: error: break statement not within loop or switch
   16 |   break;
      |   ^~~~~
Language: C++

#include<iostream>
using namespace std;
int main(void){
std::string str1 = "A";
std::string str2 = "C";
std::string str3 = "G";
std::string str4 = "T";
if(cin >> str1){
  cout << str4 << endl;}
  else(cin >> str2);{
    cout << str3 << endl;}
  if (else)(cin >> str3);{
    cout << str2 << endl;}
  if (else)(cin >> str4);{
    cout << str1 << endl;}
}


Compiler output:
a.cc: In function 'int main()':
a.cc:12:7: error: expected primary-expression before 'else'
   12 |   if (else)(cin >> str3);{
      |       ^~~~
a.cc:12:7: error: expected ')' before 'else'
   12 |   if (else)(cin >> str3);{
      |      ~^~~~
      |       )
a.cc:14:7: error: expected primary-expression before 'else'
   14 |   if (else)(cin >> str4);{
      |       ^~~~
a.cc:14:7: error: expected ')' before 'else'
   14 |   if (else)(cin >> str4);{
      |      ~^~~~
      |       )
Language: C++

#include<iostream>
using namespace std;
int main(void){
std::string str1 = "A";
std::string str2 = "C";
std::string str3 = "G";
std::string str4 = "T";
if(cin >> str1){
  cout << str4 << endl;}
  else(cin >> str2);{
    cout << str3 << endl;}
  if (else(cin >> str3);{
    cout << str2 << endl;}
  if (else(cin >> str4);{
    cout << str1 << endl;}
}


Compiler output:
a.cc: In function 'int main()':
a.cc:12:7: error: expected primary-expression before 'else'
   12 |   if (else(cin >> str3);{
      |       ^~~~
a.cc:12:25: error: expected primary-expression before '{' token
   12 |   if (else(cin >> str3);{
      |                         ^
a.cc:12:25: error: expected ')' before '{' token
   12 |   if (else(cin >> str3);{
      |      ~                  ^
      |                         )
Language: C++

#include<iostream>
using namespace std;
int main(void){
std::string str1 = "A";
std::string str2 = "C";
std::string str3 = "G";
std::string str4 = "T";
if(cin >> str1){
  cout << str4 << endl;}
  else(cin >> str2);{
    cout << str3 << endl;}
  if else(cin >> str3);{
    cout << str2 << endl;}
  if else(cin >> str4);{
    cout << str1 << endl;}
}


Compiler output:
a.cc: In function 'int main()':
a.cc:12:6: error: expected '(' before 'else'
   12 |   if else(cin >> str3);{
      |      ^~~~
      |      (
a.cc:14:6: error: expected '(' before 'else'
   14 |   if else(cin >> str4);{
      |      ^~~~
      |      (
Language: C++

#include<iostream>
using namespace std;
int main(void){
std::string str1 = "A";
std::string str2 = "C";
std::string str3 = "G";
std::string str4 = "T";
if(cin >> str1){
  cout << str4 << endl;}
  else(cin >> str2);{
    cout << str3 << endl;}
  else(cin >> str3);{
    cout << str2 << endl;}
  else(cin >> str4);{
    cout << str1 << endl;}
}


Compiler output:
a.cc: In function 'int main()':
a.cc:12:3: error: 'else' without a previous 'if'
   12 |   else(cin >> str3);{
      |   ^~~~
a.cc:14:3: error: 'else' without a previous 'if'
   14 |   else(cin >> str4);{
      |   ^~~~