Language: C++

#include <iostream>
using namespace std;
#include<bits/stdc++.h>
int main() {
	int n;
	cin>>n;
	vector<string>m(4,0);
	while(n--){
	    string s;
	    cin>>s;
	    m[s]++;
	}
	cout<<"AC"<<" "<<"x"<<" "<<m["AC"];
	cout<<"WA"<<" "<<"x"<<" "<<m["WA"];
	cout<<"TLE"<<" "<<"x"<<" "<<m["TLE"];
	cout<<"RE"<<" "<<"x"<<" "<<m["RE"];
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:11:14: error: no match for 'operator[]' (operand types are 'std::vector<std::__cxx11::basic_string<char> >' and 'std::string' {aka 'std::__cxx11::basic_string<char>'})
   11 |             m[s]++;
      |              ^
In file included from /usr/include/c++/14/vector:66,
                 from /usr/include/c++/14/functional:64,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:53,
                 from a.cc:3:
/usr/include/c++/14/bits/stl_vector.h:1128:7: note: candidate: 'std::vector<_Tp, _Alloc>::reference std::vector<_Tp, _Alloc>::operator[](size_type) [with _Tp = std::__cxx11::basic_string<char>; _Alloc = std::allocator<std::__cxx11::basic_string<char> >; reference = std::__cxx11::basic_string<char>&; size_type = long unsigned int]'
 1128 |       operator[](size_type __n) _GLIBCXX_NOEXCEPT
      |       ^~~~~~~~
/usr/include/c++/14/bits/stl_vector.h:1128:28: note:   no known conversion for argument 1 from 'std::string' {aka 'std::__cxx11::basic_string<char>'} to 'std::vector<std::__cxx11::basic_string<char> >::size_type' {aka 'long unsigned int'}
 1128 |       operator[](size_type __n) _GLIBCXX_NOEXCEPT
      |                  ~~~~~~~~~~^~~
/usr/include/c++/14/bits/stl_vector.h:1147:7: note: candidate: 'std::vector<_Tp, _Alloc>::const_reference std::vector<_Tp, _Alloc>::operator[](size_type) const [with _Tp = std::__cxx11::basic_string<char>; _Alloc = std::allocator<std::__cxx11::basic_string<char> >; const_reference = const std::__cxx11::basic_string<char>&; size_type = long unsigned int]'
 1147 |       operator[](size_type __n) const _GLIBCXX_NOEXCEPT
      |       ^~~~~~~~
/usr/include/c++/14/bits/stl_vector.h:1147:28: note:   no known conversion for argument 1 from 'std::string' {aka 'std::__cxx11::basic_string<char>'} to 'std::vector<std::__cxx11::basic_string<char> >::size_type' {aka 'long unsigned int'}
 1147 |       operator[](size_type __n) const _GLIBCXX_NOEXCEPT
      |                  ~~~~~~~~~~^~~
a.cc:13:38: error: invalid conversion from 'const char*' to 'std::vector<std::__cxx11::basic_string<char> >::size_type' {aka 'long unsigned int'} [-fpermissive]
   13 |         cout<<"AC"<<" "<<"x"<<" "<<m["AC"];
      |                                      ^~~~
      |                                      |
      |                                      const char*
/usr/include/c++/14/bits/stl_vector.h:1128:28: note:   initializing argument 1 of 'std::vector<_Tp, _Alloc>::reference std::vector<_Tp, _Alloc>::operator[](size_type) [with _Tp = std::__cxx11::basic_string<char>; _Alloc = std::allocator<std::__cxx11::basic_string<char> >; reference = std::__cxx11::basic_string<char>&; size_type = long unsigned int]'
 1128 |       operator[](size_type __n) _GLIBCXX_NOEXCEPT
      |                  ~~~~~~~~~~^~~
a.cc:14:38: error: invalid conversion from 'const char*' to 'std::vector<std::__cxx11::basic_string<char> >::size_type' {aka 'long unsigned int'} [-fpermissive]
   14 |         cout<<"WA"<<" "<<"x"<<" "<<m["WA"];
      |                                      ^~~~
      |                                      |
      |                                      const char*
/usr/include/c++/14/bits/stl_vector.h:1128:28: note:   initializing argument 1 of 'std::vector<_Tp, _Alloc>::reference std::vector<_Tp, _Alloc>::operator[](size_type) [with _Tp = std::__cxx11::basic_string<char>; _Alloc = std::allocator<std::__cxx11::basic_string<char> >; reference = std::__cxx11::basic_string<char>&; size_type = long unsigned int]'
 1128 |       operator[](size_type __n) _GLIBCXX_NOEXCEPT
      |                  ~~~~~~~~~~^~~
a.cc:15:39: error: invalid conversion from 'const char*' to 'std::vector<std::__cxx11::basic_string<char> >::size_type' {aka 'long unsigned int'} [-fpermissive]
   15 |         cout<<"TLE"<<" "<<"x"<<" "<<m["TLE"];
      |                                       ^~~~~
      |                                       |
      |                                       const char*
/usr/include/c++/14/bits/stl_vector.h:1128:28: note:   initializing argument 1 of 'std::vector<_Tp, _Alloc>::reference std::vector<_Tp, _Alloc>::operator[](size_type) [with _Tp = std::__cxx11::basic_string<char>; _Alloc = std::allocator<std::__cxx11::basic_string<char> >; reference = std::__cxx11::basic_string<char>&; size_type = long unsigned int]'
 1128 |       operator[](size_type __n) _GLIBCXX_NOEXCEPT
      |                  ~~~~~~~~~~^~~
a.cc:16:38: error: invalid conversion from 'const char*' to 'std::vector<std::__cxx11::basic_string<char> >::size_type' {aka 'long unsigned int'} [-fpermissive]
   16 |         cout<<"RE"<<" "<<"x"<<" "<<m["RE"];
      |                                      ^~~~
      |                                      |
      |                                      const char*
/usr/include/c++/14/bits/stl_vector.h:1128:28: note:   initializing argument 1 of 'std::vector<_Tp, _Alloc>::reference std::vector<_Tp, _Alloc>::operator[](size_type) [with _Tp = std::__cxx11::basic_string<char>; _Alloc = std::allocator<std::__cxx11::basic_string<char> >; reference = std::__cxx11::basic_string<char>&; size_type = long unsigned int]'
 1128 |       operator[](size_type __n) _GLIBCXX_NOEXCEPT
      |                  ~~~~~~~~~~^~~