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

#include <bits/stdc++.h>
//#include <string>
using namespace std;
 
int main() {
  int i,mainC,pC,wC,gC,yC = 0;
  string box;
  cin >> i;
  while(i>0){
   cin >> box;
    if(box="P")pC++;
    if(box="W")wC++;
    if(box="G")gC++;
    if(box="Y")yC++;
  }
  if(pC>0 && wC>0 && gC>0 && yC>0) cout << "Four" 
  else if(pC>0 && wC>0 && gC>0) cout << "Three"
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:11: error: could not convert 'box.std::__cxx11::basic_string<char>::operator=(((const char*)"P"))' from 'std::__cxx11::basic_string<char>' to 'bool'
   11 |     if(box="P")pC++;
      |        ~~~^~~~
      |           |
      |           std::__cxx11::basic_string<char>
a.cc:12:11: error: could not convert 'box.std::__cxx11::basic_string<char>::operator=(((const char*)"W"))' from 'std::__cxx11::basic_string<char>' to 'bool'
   12 |     if(box="W")wC++;
      |        ~~~^~~~
      |           |
      |           std::__cxx11::basic_string<char>
a.cc:13:11: error: could not convert 'box.std::__cxx11::basic_string<char>::operator=(((const char*)"G"))' from 'std::__cxx11::basic_string<char>' to 'bool'
   13 |     if(box="G")gC++;
      |        ~~~^~~~
      |           |
      |           std::__cxx11::basic_string<char>
a.cc:14:11: error: could not convert 'box.std::__cxx11::basic_string<char>::operator=(((const char*)"Y"))' from 'std::__cxx11::basic_string<char>' to 'bool'
   14 |     if(box="Y")yC++;
      |        ~~~^~~~
      |           |
      |           std::__cxx11::basic_string<char>
a.cc:16:50: error: expected ';' before 'else'
   16 |   if(pC>0 && wC>0 && gC>0 && yC>0) cout << "Four"
      |                                                  ^
      |                                                  ;
   17 |   else if(pC>0 && wC>0 && gC>0) cout << "Three"
      |   ~~~~                                            
a.cc: At global scope:
a.cc:19:1: error: expected declaration before '}' token
   19 | }
      | ^
Language: C++

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

int main() {
  int N,a;
  cin >> N >> a;
  
  for (int i=0;N>0;i++){
    if ( a == "Y" ){
      cout << Four << endl;
    }
    else {
      continue
    }
  }


Compiler output:
a.cc: In function 'int main()':
a.cc:9:12: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    9 |     if ( a == "Y" ){
      |          ~~^~~~~~
a.cc:10:15: error: 'Four' was not declared in this scope
   10 |       cout << Four << endl;
      |               ^~~~
a.cc:13:15: error: expected ';' before '}' token
   13 |       continue
      |               ^
      |               ;
   14 |     }
      |     ~          
a.cc:15:4: error: expected '}' at end of input
   15 |   }
      |    ^
a.cc:4:12: note: to match this '{'
    4 | int main() {
      |            ^
Language: C++

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

int main() {
  int N,a;
  cin >> N >> a;
  
  for (int i=0;N>0;i++){
    if (a=="Y"){
      cout << Four << endl;
    }
    else {
      continue
    }
  }


Compiler output:
a.cc: In function 'int main()':
a.cc:9:10: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    9 |     if (a=="Y"){
      |         ~^~~~~
a.cc:10:15: error: 'Four' was not declared in this scope
   10 |       cout << Four << endl;
      |               ^~~~
a.cc:13:15: error: expected ';' before '}' token
   13 |       continue
      |               ^
      |               ;
   14 |     }
      |     ~          
a.cc:15:4: error: expected '}' at end of input
   15 |   }
      |    ^
a.cc:4:12: note: to match this '{'
    4 | int main() {
      |            ^
Language: C++

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

int main() {
  int N,a;
  cin >> N >> a;
  
  for (int i=0;N>0;i=i+1){
    if (a=="Y"){
      cout << Four << endl;
    }
    else {
      continue
    }
  }


Compiler output:
a.cc: In function 'int main()':
a.cc:9:10: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    9 |     if (a=="Y"){
      |         ~^~~~~
a.cc:10:15: error: 'Four' was not declared in this scope
   10 |       cout << Four << endl;
      |               ^~~~
a.cc:13:15: error: expected ';' before '}' token
   13 |       continue
      |               ^
      |               ;
   14 |     }
      |     ~          
a.cc:15:4: error: expected '}' at end of input
   15 |   }
      |    ^
a.cc:4:12: note: to match this '{'
    4 | int main() {
      |            ^
Language: C++

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

int main() {
  int N,a;
  cin >> N >> a;
  
  for (int i=0;N>0;i=i++){
    if (a=="Y"){
      cout << Four << endl;
    }
    else {
      continue
    }
  }

Compiler output:
a.cc: In function 'int main()':
a.cc:9:10: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    9 |     if (a=="Y"){
      |         ~^~~~~
a.cc:10:15: error: 'Four' was not declared in this scope
   10 |       cout << Four << endl;
      |               ^~~~
a.cc:13:15: error: expected ';' before '}' token
   13 |       continue
      |               ^
      |               ;
   14 |     }
      |     ~          
a.cc:15:4: error: expected '}' at end of input
   15 |   }
      |    ^
a.cc:4:12: note: to match this '{'
    4 | int main() {
      |            ^
Language: C++

#include<bits/stdc++.h>
using namespace std;
 
int main(){
  int N;
  cin >>N;
  for(i=0;i<N;i++){
    string c;
    cin >> c;
    if(c=="Y"){
      cout <<"Four"<<endl;
    }
  }
   cout <<"Three"<<endl;
}

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

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

int main(){
  int N;
  cin >>N;
  for(i=0;i<N;i++){
    string f;
    cin >> c;
    if(c=="Y"){
      cout <<"Four"<<endl;
    }
  }
   cout <<"Three"<<endl;
}

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

#include <bits/stdc++.h>
using namespace std;
 
int main() {
    int n;
    cin >> n;
    string s[n];
    for(int i = 0;i < n;i++){
        cin >> s[i];
    }

    s.erase(unique(s.begin(), s.end()), s.end());
    cout << s.size() << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:7: error: request for member 'erase' in 's', which is of non-class type 'std::string [n]' {aka 'std::__cxx11::basic_string<char> [n]'}
   12 |     s.erase(unique(s.begin(), s.end()), s.end());
      |       ^~~~~
a.cc:12:22: error: request for member 'begin' in 's', which is of non-class type 'std::string [n]' {aka 'std::__cxx11::basic_string<char> [n]'}
   12 |     s.erase(unique(s.begin(), s.end()), s.end());
      |                      ^~~~~
a.cc:12:33: error: request for member 'end' in 's', which is of non-class type 'std::string [n]' {aka 'std::__cxx11::basic_string<char> [n]'}
   12 |     s.erase(unique(s.begin(), s.end()), s.end());
      |                                 ^~~
a.cc:12:43: error: request for member 'end' in 's', which is of non-class type 'std::string [n]' {aka 'std::__cxx11::basic_string<char> [n]'}
   12 |     s.erase(unique(s.begin(), s.end()), s.end());
      |                                           ^~~
a.cc:13:15: error: request for member 'size' in 's', which is of non-class type 'std::string [n]' {aka 'std::__cxx11::basic_string<char> [n]'}
   13 |     cout << s.size() << endl;
      |               ^~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main() {
    int n;
    cin >> n;
    string s[n];
    for(i = 0;i < n;i++){
        cin >> s[i];
    }
    s.erase(unique(s.begin(), s.end()), s.end());
    cout << s.size() << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:9: error: 'i' was not declared in this scope
    8 |     for(i = 0;i < n;i++){
      |         ^
a.cc:11:7: error: request for member 'erase' in 's', which is of non-class type 'std::string [n]' {aka 'std::__cxx11::basic_string<char> [n]'}
   11 |     s.erase(unique(s.begin(), s.end()), s.end());
      |       ^~~~~
a.cc:11:22: error: request for member 'begin' in 's', which is of non-class type 'std::string [n]' {aka 'std::__cxx11::basic_string<char> [n]'}
   11 |     s.erase(unique(s.begin(), s.end()), s.end());
      |                      ^~~~~
a.cc:11:33: error: request for member 'end' in 's', which is of non-class type 'std::string [n]' {aka 'std::__cxx11::basic_string<char> [n]'}
   11 |     s.erase(unique(s.begin(), s.end()), s.end());
      |                                 ^~~
a.cc:11:43: error: request for member 'end' in 's', which is of non-class type 'std::string [n]' {aka 'std::__cxx11::basic_string<char> [n]'}
   11 |     s.erase(unique(s.begin(), s.end()), s.end());
      |                                           ^~~
a.cc:12:15: error: request for member 'size' in 's', which is of non-class type 'std::string [n]' {aka 'std::__cxx11::basic_string<char> [n]'}
   12 |     cout << s.size() << endl;
      |               ^~~~
Language: C++

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

int main() {
  int N
  cin >> N;
  string s;
  bool isFour = false;

  for (int i = 0; i < N; i++) {
    cin >> s;
    if (s == "Y") {
      isFour = true;
      break;
    }
  }
  if (isFour) {
    cout << "Four" << endl;
  } else {
    cout << "Three" << endl;
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:3: error: expected initializer before 'cin'
    6 |   cin >> N;
      |   ^~~
a.cc:10:23: error: 'N' was not declared in this scope
   10 |   for (int i = 0; i < N; i++) {
      |                       ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, i, a;
  string s;
  a=0;
  cin >> n;
  bool can=true;
  for(i=0;i<n;i++) {
    cin >> s;
      if(s == "Y") {
        can=false
        break;
      }
  }
  if(can) {
    cout << "Three" << endl;
  }
  else {
    cout << "Four" << endl;
  }
  return 0;
}
        


Compiler output:
a.cc: In function 'int main()':
a.cc:12:18: error: expected ';' before 'break'
   12 |         can=false
      |                  ^
      |                  ;
   13 |         break;
      |         ~~~~~
Language: C++

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

int main() {
  
  int N;
  cin >> N;
  string S;
  for(int i=0; i<N; i++){
    cin >> S;
      if (S == "y"){
        cout << "Four" << endl;
        break;
      }
    else if(i == N-1) {
    cout << "Three" << endl;
}
  }
    


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

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

int main() {
  
  int N;
  cin >> N;
   string S;
  for(int i=0; i<N; i++){
    cin >> S;
      if (S == "y"){
        cout << "Four" << endl;
        break;
      }
  }
  if(i == N){
    cout << "Three" << endl;
 }
}


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

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

int main() {
  
  int N;
  cin >> N;
  
  for(int i=0; i<N; i++){
    string S;
    cin >> S
      if (S == "y"){
        cout << "Four" << endl;
        break;
      }
  }
    cout << "Three" << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:13: error: expected ';' before 'if'
   11 |     cin >> S
      |             ^
      |             ;
   12 |       if (S == "y"){
      |       ~~
Language: C++

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

int main() {
  int N;
  char x;
  cin>>N>>x;
  
  for (int i = 0; i < N; i++) {
    if (x=="Y"){
      cout<<"Four"<<endl;
      break;
    }
    else if(i==N--){
      cout<<"Three"<<endl;
    }
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:10:10: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   10 |     if (x=="Y"){
      |         ~^~~~~
Language: C++

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

int main() {
  int N;
  char x;
  cin>>N;
  
  for (int i = 0; i < N; i++) {
    int x;
    cin >>x;
    if (x=="Y"){
      cout<<"Four"<<endl;
      break;
    }
    else if(i==N--){
      cout<<"Three"<<endl;
    }
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:10: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   12 |     if (x=="Y"){
      |         ~^~~~~
Language: C++

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

int main() {
  int N;
  cin>>N;
  
  for (int i = 0; i < N; i++) {
    int x;
    cin >>x;
    if (x=="Y"){
      cout<<"Four"<<endl;
      break;
    }
    else if(i==N--){
      cout<<"Three"<<endl;
    }
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:10: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   11 |     if (x=="Y"){
      |         ~^~~~~
Language: C++

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

int main()
{
  int N;
  cin >> N;
  int S;
  bool tf = false;
  for (int i = 0; i < N; i++)
  {
    cin >> S;
    if (S == "Y")
    {
      tf = true;
    }
  }
  if (tf)
  {
    cout << "Four" << endl;
  }
  else
  {
    cout << "Three" << endl;
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:13:11: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   13 |     if (S == "Y")
      |         ~~^~~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main() {
  int N;
  cin >> N;
  
  for (int i =0; i < N; i++) {
    string i;
    cin >> i;
    if (i == "Y") {
    cout << "Four" << endl; 
    break;
  }
  else {
    cout << "Three" << endl;
    break;
  }
    
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:12: error: redeclaration of 'std::string i'
    9 |     string i;
      |            ^
a.cc:8:12: note: 'int i' previously declared here
    8 |   for (int i =0; i < N; i++) {
      |            ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main() {
  int N;
  cin >> N;
  
  for (int i =0; i < N; i++) {
    string si = c;
    cin >> si;
    if (c == "Y") {
    cout << "Four" << endl; 
    break;
  }
  else {
    cout << "Three" << endl;
    break;
  }
    
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:17: error: 'c' was not declared in this scope
    9 |     string si = c;
      |                 ^
Language: C++

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

int main() {
  int N;
  cin >> N;
  
  string S = 0;
  bool flag = false;
  
  for (int i = 0; i < N; i++) {
    cin >> S[i];
    
    if (S[i] == "Y") {
      flag = true;
      break;
    }
  }
  
  if (flag == true) {
    cout << "Three" << endl;
  } else {
    cout << "Four" << endl;
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:14:14: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   14 |     if (S[i] == "Y") {
Language: C++

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

int main() {
  int N;
  cin >> N;
  
  string S = 0;
  
  for (int i = 0; i < N; i++) {
    cin >> S[i];
    
    if (S[i] == "Y") {
      cout << "Four" << endl;
      break;
    }
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:14: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   13 |     if (S[i] == "Y") {
Language: C++

#include <bits/stdc++.h>
using namespace std;
int N;
char c;
int main() {
  scanf("%d",&N);
  bool flag = false;
  for(int i = 0; i < N; i++){
    scanf("%c",&c);
    if(c == "Y")flag=true;
  
  }
  if(flag)puts("Four");
  else puts("Three");
}


Compiler output:
a.cc: In function 'int main()':
a.cc:10:10: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   10 |     if(c == "Y")flag=true;
      |        ~~^~~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main() {
  int N;
  
  cin >> N;
  
  for (i=0;i<N;i++){
    string color;
    cin >> color;
    int ans = 3; 
    if (color=="Y"){
    ans = 4;
    } 
  }
  if(ans == 4){
    cout << "Four"<<endl;
  }else{
    cout << "Three"<<endl;
  }
  return 0;
}



Compiler output:
a.cc: In function 'int main()':
a.cc:9:8: error: 'i' was not declared in this scope
    9 |   for (i=0;i<N;i++){
      |        ^
a.cc:17:6: error: 'ans' was not declared in this scope; did you mean 'abs'?
   17 |   if(ans == 4){
      |      ^~~
      |      abs
Language: C++

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

int main() {
  int N;
  cin >> N;
  char s[N-1];
  cin >> s;
  int i;
  int p,y,w,g;
  for(i=0;i < N; i++){
    if(p == 0 && s[i] == "P") p ++ ;
    else if(y == 0 && s[i] == "Y") y ++ ;
    else if(w == 0 && s[i] == "W") w ++ ;
    else if(g == 0 && s[i] == "G") g ++ ;
  }
  if(p + y + w + g == 3) cout << "Three" << endl;
  if(p + y + w + g == 4) cout << "Four" << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:12:23: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   12 |     if(p == 0 && s[i] == "P") p ++ ;
      |                  ~~~~~^~~~~~
a.cc:13:28: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   13 |     else if(y == 0 && s[i] == "Y") y ++ ;
      |                       ~~~~~^~~~~~
a.cc:14:28: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   14 |     else if(w == 0 && s[i] == "W") w ++ ;
      |                       ~~~~~^~~~~~
a.cc:15:28: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   15 |     else if(g == 0 && s[i] == "G") g ++ ;
      |                       ~~~~~^~~~~~
Language: C++

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

int main() {
  int N;
  cin >> N;
  char s[N-1];
  cin >> s;
  int i;
  int p,y,w,g;
  for(i=0;i < N; i++){
    if(p == 0 && s[i] == "P") p +=;
    else if(y == 0 && s[i] == "Y") y +=;
    else if(w == 0 && s[i] == "W") w +=;
    else if(g == 0 && s[i] == "G") g +=;
  }
  if(p + y + w + g == 3) cout << "Three" << endl;
  if(p + y + w + g == 4) cout << "Four" << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:12:23: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   12 |     if(p == 0 && s[i] == "P") p +=;
      |                  ~~~~~^~~~~~
a.cc:12:35: error: expected primary-expression before ';' token
   12 |     if(p == 0 && s[i] == "P") p +=;
      |                                   ^
a.cc:13:28: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   13 |     else if(y == 0 && s[i] == "Y") y +=;
      |                       ~~~~~^~~~~~
a.cc:13:40: error: expected primary-expression before ';' token
   13 |     else if(y == 0 && s[i] == "Y") y +=;
      |                                        ^
a.cc:14:28: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   14 |     else if(w == 0 && s[i] == "W") w +=;
      |                       ~~~~~^~~~~~
a.cc:14:40: error: expected primary-expression before ';' token
   14 |     else if(w == 0 && s[i] == "W") w +=;
      |                                        ^
a.cc:15:28: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   15 |     else if(g == 0 && s[i] == "G") g +=;
      |                       ~~~~~^~~~~~
a.cc:15:40: error: expected primary-expression before ';' token
   15 |     else if(g == 0 && s[i] == "G") g +=;
      |                                        ^
Language: C++

            #include <bits/stdc++.h>
            using namespace std;
             
            int main() {
              int N, p, y , w, g, i, sum;
              
              cin >> N;
              cout << endl;
              bool flag = false;
              strinng x;
              
              for(i = 0; i < N; i++){
                cin >> x;
                if (x == "Y") flag = true;
              }
              if (flag){cout << "Four"}
              else {cout << "Three"}
            }

Compiler output:
a.cc: In function 'int main()':
a.cc:10:15: error: 'strinng' was not declared in this scope
   10 |               strinng x;
      |               ^~~~~~~
a.cc:13:24: error: 'x' was not declared in this scope
   13 |                 cin >> x;
      |                        ^
a.cc:16:39: error: expected ';' before '}' token
   16 |               if (flag){cout << "Four"}
      |                                       ^
      |                                       ;
a.cc:17:36: error: expected ';' before '}' token
   17 |               else {cout << "Three"}
      |                                    ^
      |                                    ;
Language: C++

            #include <bits/stdc++.h>
            using namespace std;
             
            int main() {
              int N, p, y , w, g, i, sum;
              
              cin >> N;
              cout << endl;
              char x[];
              
              for(i = 0; i < N; i++){
                cin >> x[i];
              if (x[i] == P ){
                p = 1;
              }else if (x[i] == Y){
                y = 1;
              }else if (x[i] == W){
                w = 1;
              }else if (x[i] == G){
                g = 1;
              }
              }
              sum = p + y + w + g;
              if(sum == 3){
                cout << sum << endl;
              } else if (sum == 4 ){
                cout << sum << endl;
              }
              
            }

Compiler output:
a.cc: In function 'int main()':
a.cc:9:20: error: storage size of 'x' isn't known
    9 |               char x[];
      |                    ^
a.cc:13:27: error: 'P' was not declared in this scope
   13 |               if (x[i] == P ){
      |                           ^
a.cc:15:33: error: 'Y' was not declared in this scope
   15 |               }else if (x[i] == Y){
      |                                 ^
a.cc:17:33: error: 'W' was not declared in this scope
   17 |               }else if (x[i] == W){
      |                                 ^
a.cc:19:33: error: 'G' was not declared in this scope
   19 |               }else if (x[i] == G){
      |                                 ^
Language: C++

    #include <bits/stdc++.h>
                using namespace std;
                 
                int main() {
                  int N, p, y , w, g, i, sum;
                  
                  cin >> N;
                  cout << endl;
                  string x;
                  
                  for(i = 0; i < N; i++){
                    cin >> x;
                  if (x[i] == "P"){
                    p = 1;
                  }else if (x[i] == "Y"){
                    y = 1;
                  }else if (x[i] == "W"){
                    w = 1;
                  }else if (x[i] == "G"){
                    g = 1;
                  }
                  }
                  sum = p + y + w + g;
                  if(sum == 3){
                    cout << sum << endl;
                  } else if (sum == 4 ){
                    cout << sum << endl;
                  }
                  
                }

            #include <bits/stdc++.h>
            using namespace std;
             
            int main() {
              int N, p, y , w, g, i, sum;
              
              cin >> N;
              cout << endl;
              char x[N]={};

              for(i = 0; i < N; i++){
                cin >> x;
              if (x == "P"){
                p = 1;
              }else if (x == "Y"){
                y = 1;
              }else if (x == "W"){
                w = 1;
              }else if (x == "G"){
                g = 1;
              }
              }
              sum = p + y + w + g;
              if(sum == 3){
                cout << sum << endl;
              } else if (sum == 4 ){
                cout << sum << endl;
              }
              
            }

Compiler output:
a.cc: In function 'int main()':
a.cc:13:28: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   13 |                   if (x[i] == "P"){
a.cc:15:34: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   15 |                   }else if (x[i] == "Y"){
a.cc:17:34: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   17 |                   }else if (x[i] == "W"){
a.cc:19:34: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   19 |                   }else if (x[i] == "G"){
a.cc: At global scope:
a.cc:35:17: error: redefinition of 'int main()'
   35 |             int main() {
      |                 ^~~~
a.cc:4:21: note: 'int main()' previously defined here
    4 |                 int main() {
      |                     ^~~~
Language: C++

            #include <bits/stdc++.h>
            using namespace std;
             
            int main() {
              int N, p, y , w, g, i, sum;
              
              cin >> N;
              cout << endl;
              char x[N]={};

              for(i = 0; i < N; i++){
                cin >> x;
              if (x[i] == "P"){
                p = 1;
              }else if (x[i] == "Y"){
                y = 1;
              }else if (x[i] == "W"){
                w = 1;
              }else if (x[i] == "G"){
                g = 1;
              }
              }
              sum = p + y + w + g;
              if(sum == 3){
                cout << sum << endl;
              } else if (sum == 4 ){
                cout << sum << endl;
              }
              
            }

Compiler output:
a.cc: In function 'int main()':
a.cc:13:24: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   13 |               if (x[i] == "P"){
      |                   ~~~~~^~~~~~
a.cc:15:30: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   15 |               }else if (x[i] == "Y"){
      |                         ~~~~~^~~~~~
a.cc:17:30: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   17 |               }else if (x[i] == "W"){
      |                         ~~~~~^~~~~~
a.cc:19:30: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   19 |               }else if (x[i] == "G"){
      |                         ~~~~~^~~~~~
Language: C++

            #include <bits/stdc++.h>
            using namespace std;
             
            int main() {
              int N, p, y , w, g, i, sum;
              
              cin >> N;
              cout << endl;
              char x[N];

              for(i = 0; i < N; i++){
                cin >> x;
              if (x[i] == "P"){
                p = 1;
              }else if (x[i] == "Y"){
                y = 1;
              }else if (x[i] == "W"){
                w = 1;
              }else if (x[i] == "G"){
                g = 1;
              }
              }
              sum = p + y + w + g;
              if(sum == 3){
                cout << sum << endl;
              } else if (sum == 4 ){
                cout << sum << endl;
              }
              
            }

Compiler output:
a.cc: In function 'int main()':
a.cc:13:24: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   13 |               if (x[i] == "P"){
      |                   ~~~~~^~~~~~
a.cc:15:30: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   15 |               }else if (x[i] == "Y"){
      |                         ~~~~~^~~~~~
a.cc:17:30: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   17 |               }else if (x[i] == "W"){
      |                         ~~~~~^~~~~~
a.cc:19:30: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   19 |               }else if (x[i] == "G"){
      |                         ~~~~~^~~~~~
Language: C++

            #include <bits/stdc++.h>
            using namespace std;
             
            int main() {
              int N, p, y , w, g, i, sum;
              
              cin >> N;
              cout << endl;
              char x[];

              for(i = 0; i < N; i++){
                cin >> x;
              if (x[i] == "P"){
                p = 1;
              }else if (x[i] == "Y"){
                y = 1;
              }else if (x[i] == "W"){
                w = 1;
              }else if (x[i] == "G"){
                g = 1;
              }
              }
              sum = p + y + w + g;
              if(sum == 3){
                cout << sum << endl;
              } else if (sum == 4 ){
                cout << sum << endl;
              }
              
            }

Compiler output:
a.cc: In function 'int main()':
a.cc:9:20: error: storage size of 'x' isn't known
    9 |               char x[];
      |                    ^
Language: C++

            #include <bits/stdc++.h>
            using namespace std;
             
            int main() {
              int N, p, y , w, g, i, sum;
              
              cin >> N;
              cout << endl;
              string x;

              for(i = 0; i < N; i++){
                cin >> x;
              if (x == "P"){
                p = 1;
              }else if (x == "Y"){
                y = 1;
              }else if (x == "W"){
                w = 1;
              }else if (x == "G"){
                g = 1;
              }
              }
              sum = p + y + w + g
              if(sum == 3){
                cout << sum << endl;
              } else if (sum == 4 ){
                cout << sum << endl;
              }
              
            }

Compiler output:
a.cc: In function 'int main()':
a.cc:23:34: error: expected ';' before 'if'
   23 |               sum = p + y + w + g
      |                                  ^
      |                                  ;
   24 |               if(sum == 3){
      |               ~~                  
a.cc:26:17: error: 'else' without a previous 'if'
   26 |               } else if (sum == 4 ){
      |                 ^~~~
Language: C++

            #include <bits/stdc++.h>
            using namespace std;
             
            int main() {
              int N, p, y , w, g, i, sum;
              
              cin >> N;
              cout << endl;
              char arare[N];

              for(i = 0; i < N; i++){
              cin >> arare[i];
              }
              
              for(i = 0; i < N; i++){
              if (arare[i] == "P"){
                p = 1;
              }else if (arare[i] == "Y"){
                y = 1;
              }else if (arare[i] == "W"){
                w = 1;
              }else if (arare[i] == "G"){
                g = 1;
              }
              }
              sum = p + y + w + g
              if(sum == 3){
                cout << sum << endl;
              } else if (sum == 4 ){
                cout << sum << endl;
              }
              
            }

Compiler output:
a.cc: In function 'int main()':
a.cc:16:28: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   16 |               if (arare[i] == "P"){
      |                   ~~~~~~~~~^~~~~~
a.cc:18:34: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   18 |               }else if (arare[i] == "Y"){
      |                         ~~~~~~~~~^~~~~~
a.cc:20:34: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   20 |               }else if (arare[i] == "W"){
      |                         ~~~~~~~~~^~~~~~
a.cc:22:34: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   22 |               }else if (arare[i] == "G"){
      |                         ~~~~~~~~~^~~~~~
a.cc:26:34: error: expected ';' before 'if'
   26 |               sum = p + y + w + g
      |                                  ^
      |                                  ;
   27 |               if(sum == 3){
      |               ~~                  
a.cc:29:17: error: 'else' without a previous 'if'
   29 |               } else if (sum == 4 ){
      |                 ^~~~
Language: C++

            #include <bits/stdc++.h>
            using namespace std;
             
            int main() {
              int N, p, y , w, g, i, sum;
              char arare[];
              
              cin >> N;
              cout << endl;
              for(i = 0; i < N; i++){
              cin >> arare[i] >> " ";
              }
              
              for(i = 0; i < N; i++){
              if (arare[i] == "P"){
                p = 1;
              }else if (arare[i] == "Y"){
                y = 1;
              }else if (arare[i] == "W"){
                w = 1;
              }else if (arare[i] == "G"){
                g = 1;
              }
              }
              sum = p + y + w + g
              if(sum == 3){
                cout << sum << endl;
              } else if (sum == 4 ){
                cout << sum << endl;
              }
              
            }

Compiler output:
a.cc: In function 'int main()':
a.cc:6:20: error: storage size of 'arare' isn't known
    6 |               char arare[];
      |                    ^~~~~
a.cc:25:34: error: expected ';' before 'if'
   25 |               sum = p + y + w + g
      |                                  ^
      |                                  ;
   26 |               if(sum == 3){
      |               ~~                  
a.cc:28:17: error: 'else' without a previous 'if'
   28 |               } else if (sum == 4 ){
      |                 ^~~~
Language: C++

            #include <bits/stdc++.h>
            using namespace std;
             
            int main() {
              int N, p, y , w, g;
              char arare[] = {};
              
              cin >> N;
              cout << endl;
              for(i = 0; i < N; i++){
              cin >> arare[i] >> " ";
              }
              
              for(i = 0; i < N; i++){
              if (arare[i] == "P"){
                p = 1;
              }else if (arare[i] == "Y"){
                y = 1;
              }else if (arare[i] == "W"){
                w = 1;
              }else if (arare[i] == "G"){
                g = 1;
              }
              }
              sum = p + y + w + g
              if(sum == 3){
                cout << sum << endl;
              } else if (sum == 4 ){
                cout << sum << endl;
              }
              
            }

Compiler output:
a.cc: In function 'int main()':
a.cc:10:19: error: 'i' was not declared in this scope
   10 |               for(i = 0; i < N; i++){
      |                   ^
a.cc:14:19: error: 'i' was not declared in this scope
   14 |               for(i = 0; i < N; i++){
      |                   ^
a.cc:25:15: error: 'sum' was not declared in this scope
   25 |               sum = p + y + w + g
      |               ^~~
a.cc:28:17: error: 'else' without a previous 'if'
   28 |               } else if (sum == 4 ){
      |                 ^~~~
Language: C++

            #include <bits/stdc++.h>
            using namespace std;
             
            int main() {
              int N, p, y , w, g;
              char arare[] = {};
              
              cin >> N;
              cout << endl;
              for(i = 0; i< N; << i++){
              cin >> arare[i] >> " ";
              }
              
              for(i = 0; i< N; << i++){
              if (arare[i] == "P"){
                p = 1;
              }else if (arare[i] == "Y"){
                y = 1;
              }else if (arare[i] == "W"){
                w = 1;
              }else if (arare[i] == "G"){
                g = 1;
              }
              }
              sum = p + y + w + g
              if(sum == 3){
                cout << sum << endl;
              } else if (sum == 4 ){
                cout << sum << endl;
              }
              
            }

Compiler output:
a.cc: In function 'int main()':
a.cc:10:19: error: 'i' was not declared in this scope
   10 |               for(i = 0; i< N; << i++){
      |                   ^
a.cc:10:32: error: expected primary-expression before '<<' token
   10 |               for(i = 0; i< N; << i++){
      |                                ^~
a.cc:14:19: error: 'i' was not declared in this scope
   14 |               for(i = 0; i< N; << i++){
      |                   ^
a.cc:14:32: error: expected primary-expression before '<<' token
   14 |               for(i = 0; i< N; << i++){
      |                                ^~
a.cc:25:15: error: 'sum' was not declared in this scope
   25 |               sum = p + y + w + g
      |               ^~~
a.cc:28:17: error: 'else' without a previous 'if'
   28 |               } else if (sum == 4 ){
      |                 ^~~~
Language: C++

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

int main() {
    int n, s;
    string ans;
    for (int i = 0; i < n; i++)
    {
        cin >> s;
        if (s == "Y") {
            cout << "Four" << endl;
            break;
        }
    }
    cout << "Three" << endl;
    
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:15: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   10 |         if (s == "Y") {
      |             ~~^~~~~~
Language: C++

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

int main() {
  int N;
  cin >> N;
  for(int i = 0; i < N; i++){
    string S;
    cin >> S;
    if(S == "Y"){
      cout << "Four" << endl;
      break;
    }
    else if(S == "P" || S == "W" || S == "G"){
      continue;
    }
    else if(S != "Y" && i = N-1){
      cout << "Three" << endl;
    }
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:17:22: error: lvalue required as left operand of assignment
   17 |     else if(S != "Y" && i = N-1){
      |             ~~~~~~~~~^~~~
Language: C++

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

int main() {
  int N;
  cin >> N;
  for(int i = 0; i < N; i++){
    string S;
    cin >> S;
    if(S == "Y"){
      cout << "Four" << endl;
      break;
    }
    else if(S == "P" || S == "W" || S == "G"){
      continue;
    }
    else if(S != "Y" || i = N-1){
      cout << "Three" << endl;
    }
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:17:22: error: lvalue required as left operand of assignment
   17 |     else if(S != "Y" || i = N-1){
      |             ~~~~~~~~~^~~~
Language: C++

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

int main() {
 
  for(int x = 0; x < N; x++){
     int N;
  string S;
  cin >> N >> S;
    if(S == "Y"){
      cout << "Four" << endl;
    }
    else{
      cout << "Three" << endl;
    }
  }
    
}


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

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

int main() {
  int a,b;
  string s;
  cin >> a;
  
  for(i = 0; i < a; i++){
    cin >> s;
    if( s == "Y" ){
    cout << "Four" << endl;
      
    return 0;
  }
  }
  
   cout << "Three" << endl;
  
}
 
  
  
  
 

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

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

int main() {
  int N(0);
  cin >> N; 
  string color[N];
  for(int i = 0; i < N; i++)
  {
   	cin >> color[i];
  }
  
  for(int i = 0; i < N; i++)
  {
	if( color[i] == "Y" )
    {
      cout << "Four" << endl;
      return 0;
    }	
  }
  cout << "Three" << endl;




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

#include <iostream>
using namespace std;

int main() {
  int N, kind =3;
  string c;
  cin >> N
  for(int i =0; i < N; i++){
    cin >> c;
    if(c == "Y"){
      kind = 4;
    }
  }
  if(kind == 4){
    cout << "Four" << endl;
  }
  else{
    cout << "Three" << endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:11: error: expected ';' before 'for'
    7 |   cin >> N
      |           ^
      |           ;
    8 |   for(int i =0; i < N; i++){
      |   ~~~      
a.cc:8:17: error: 'i' was not declared in this scope
    8 |   for(int i =0; i < N; i++){
      |                 ^
Language: C++

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

int main(){
 int N;
  for(int i=0; i<N;i++){
    string S;
    cin>>S;
    int a=0;
    int b=0;
    int c=0;
    int d=0;
    int e,g,f,h,k;
    if(S=="P"){
      a++;
      for(int j=0;i<a-1;j++){
	
        f=a;
        f--;
      }
      
    }else if(S=="W"){
      b++;
       for(int j=0;i<b-1;j++){
	
        g=b;
        g--;
      }
    }else if(S=="G"){
      c++; 
      for(int j=0;i<c-1;j++){
		
        h=c;
        h--;
      }
      
      
      
    }else if(S=="Y"){ 
      d++;
      for(int j=0;i<d-1;j++){
		
        k=d;
        k--;
      }
    
    }
    e=f+g+h+k;
    
   
  }
   if(e==3){
	cout<<"Three"<<endl;
    }else{
      cout<<"Four"<<endl;
    }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:52:7: error: 'e' was not declared in this scope
   52 |    if(e==3){
      |       ^
Language: C++

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

int main(){
 int N;
  for(int i=0; i<N;i++){
    string S;
    cin>>S;
    int a=0;
    int b=0;
    int c=0;
    int d=0;
    int e;
    if(S=="P"){
      a++;
      for(int j=0;i<a-1;j++){
		int f;
        f==a;
        f--;
      }
      
    }else if(S=="W"){
      b++;
       for(int j=0;i<b-1;j++){
		int g;
        g==b;
        g--;
      }
    }else if(S=="G"){
      c++; 
      for(int j=0;i<c-1;j++){
		int h;
        h==c;
        h--;
      }
      
      
      
    }else if(S=="Y"){ 
      d++;
      for(int j=0;i<d-1;j++){
		int k;
        k==d;
        k--;
      }
    
    }
    e=f+g+h+k;
    
   
  }
   if(e==3){
	cout<<"Three"<<endl;
    }else{
      cout<<"Four"<<endl;
    }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:48:7: error: 'f' was not declared in this scope
   48 |     e=f+g+h+k;
      |       ^
a.cc:48:9: error: 'g' was not declared in this scope
   48 |     e=f+g+h+k;
      |         ^
a.cc:48:11: error: 'h' was not declared in this scope
   48 |     e=f+g+h+k;
      |           ^
a.cc:48:13: error: 'k' was not declared in this scope
   48 |     e=f+g+h+k;
      |             ^
a.cc:52:7: error: 'e' was not declared in this scope
   52 |    if(e==3){
      |       ^
Language: C++

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

int main(){
 int N;
  for(int i=0; i<N;i++){
    string S;
    cin>>S;
    int a=0;
    int b=0;
    int c=0;
    int d=0;
    int e;
    if(S=="P"){
      a=1;
    }else if(S=="W"){
      b=1;
    }else if(S=="G"){
      c=1;
    }else if(S=="Y"){
      d=1;
    }
    e=a+b+c+d;
    
    if(e==3){
	cout<<"Three"<<endl;
    }else{
      cout<<"Four"<<endl;
    }
  }

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

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

int main(){
 int N;
  for(int i=0; i<N;i++){
    cin>>S;
    int a=0;
    int b=0;
    int c=0;
    int d=0;
    int e;
    if(S=="P"){
      a=1;
    }else if(S=="W"){
      b=1;
    }else if(S=="G"){
      c=1;
    }else if(S=="Y"){
      d=1;
    }
    e=a+b+c+d;
    
    if(e==3){
	cout<<"Three"<<endl;
    }else{
      cout<<"Four"<<endl;
    }

Compiler output:
a.cc: In function 'int main()':
a.cc:7:10: error: 'S' was not declared in this scope
    7 |     cin>>S;
      |          ^
a.cc:28:6: error: expected '}' at end of input
   28 |     }
      |      ^
a.cc:6:24: note: to match this '{'
    6 |   for(int i=0; i<N;i++){
      |                        ^
a.cc:28:6: error: expected '}' at end of input
   28 |     }
      |      ^
a.cc:4:11: note: to match this '{'
    4 | int main(){
      |           ^
Language: C++

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

int main() {
  int N;
  cin >> N;
  string a[N];
  for (int i = 0; i < N; i++){
    std::cin >> a[N];
  }
  
  for (int i = 0; i < N; i++){
    int P=0;
    int G=0;
    int W=0;
    int Y=0;
    int num = 0;

    if (a[i] == "P"){
      P += 1;
    }
    else if (a[i] == "G"){
      G += 1;
    }
    else if (a[i] == "W"){
      W += 1;
    }
    else if (a[i] == "Y"){
      Y += 1;
    }

    if (P != 0){
      num++;
    }
    else if (G != 0){
      num++;
    }
    else if (W != 0){
      num++;
    }
    else if (Y != 0){
      num++;
    }

    if (num == 3){
      cout << "Three" << endl;
    }
    else if (num == 4){
      cout << "Four" << endl;
    }

}

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

#include <bits/stdc++.h>
using namespace std;
 
int main(){
  int N;
  cin >> N;
  for(int i = 0; i < N; i++){
    string S;
    cin >> S;
    int g = 0, w = 0, y = 0, p = 0;
    if(S == "G"){
      g = 1;
    }else if(S == "W"){
      w = 1;
    }else if(S == "Y"){
      y = 1;
    }else{
      p = 1;
    }
  }
  int sum = g + w + y + p;
  if(sum == 3){
    cout << "Three" << endl;
  }else{
    cout << "Four" << endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:21:13: error: 'g' was not declared in this scope
   21 |   int sum = g + w + y + p;
      |             ^
a.cc:21:17: error: 'w' was not declared in this scope
   21 |   int sum = g + w + y + p;
      |                 ^
a.cc:21:21: error: 'y' was not declared in this scope
   21 |   int sum = g + w + y + p;
      |                     ^
a.cc:21:25: error: 'p' was not declared in this scope
   21 |   int sum = g + w + y + p;
      |                         ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main(){
  int N;
  cin >> N;
  for(int i = 0; i < N; i++){
    string S;
    cin >> S;
    int g = 0, w = 0, y = 0, p = 0;
    if(S == "G"){
      g = 1
    }else if(S == "W"){
      w = 1
    }else if(S == "Y"){
      y = 1
    }else{
      p = 1
    }
  }
  int sum = g + w + y + p;
  if(sum == 3){
    cout << "Three" << endl;
  }else{
    cout << "Four" << endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:12: error: expected ';' before '}' token
   12 |       g = 1
      |            ^
      |            ;
   13 |     }else if(S == "W"){
      |     ~       
a.cc:14:12: error: expected ';' before '}' token
   14 |       w = 1
      |            ^
      |            ;
   15 |     }else if(S == "Y"){
      |     ~       
a.cc:16:12: error: expected ';' before '}' token
   16 |       y = 1
      |            ^
      |            ;
   17 |     }else{
      |     ~       
a.cc:18:12: error: expected ';' before '}' token
   18 |       p = 1
      |            ^
      |            ;
   19 |     }
      |     ~       
a.cc:21:13: error: 'g' was not declared in this scope
   21 |   int sum = g + w + y + p;
      |             ^
a.cc:21:17: error: 'w' was not declared in this scope
   21 |   int sum = g + w + y + p;
      |                 ^
a.cc:21:21: error: 'y' was not declared in this scope
   21 |   int sum = g + w + y + p;
      |                     ^
a.cc:21:25: error: 'p' was not declared in this scope
   21 |   int sum = g + w + y + p;
      |                         ^