Language: C++

#include<iostream>
#include<vector>
int main()
{
  int N,M;
  scanf("%d%d",&N,&M);
  std::vector<std::vector<int,2>,M> AB;
  for(int a = 0; a < M; a++)
  {
    std::cin>>AB[a][0]>>AB[a][1];
  }
  for(int a = 0; a < M; a++)
  {
    for(int b = (a+1); b < M; b++)
    {
      if(((AB[a][0]==AB[b][0])&&(AB[a][1]==AB[b][1]))||((AB[a][0]==AB[b][1])&&(AB[a][1]==AB[b][0])))
      {
        AB.erase(AB.begin() + b);
        M--;
      }
    }
  }
  int kekka = N - M;
  printf("%d",kekka);
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:32: error: type/value mismatch at argument 2 in template parameter list for 'template<class _Tp, class _Alloc> class std::vector'
    7 |   std::vector<std::vector<int,2>,M> AB;
      |                                ^
a.cc:7:32: note:   expected a type, got '2'
a.cc:7:35: error: template argument 1 is invalid
    7 |   std::vector<std::vector<int,2>,M> AB;
      |                                   ^
a.cc:7:35: error: type/value mismatch at argument 2 in template parameter list for 'template<class _Tp, class _Alloc> class std::vector'
a.cc:7:35: note:   expected a type, got 'M'
a.cc:10:17: error: invalid types 'int[int]' for array subscript
   10 |     std::cin>>AB[a][0]>>AB[a][1];
      |                 ^
a.cc:10:27: error: invalid types 'int[int]' for array subscript
   10 |     std::cin>>AB[a][0]>>AB[a][1];
      |                           ^
a.cc:16:14: error: invalid types 'int[int]' for array subscript
   16 |       if(((AB[a][0]==AB[b][0])&&(AB[a][1]==AB[b][1]))||((AB[a][0]==AB[b][1])&&(AB[a][1]==AB[b][0])))
      |              ^
a.cc:16:24: error: invalid types 'int[int]' for array subscript
   16 |       if(((AB[a][0]==AB[b][0])&&(AB[a][1]==AB[b][1]))||((AB[a][0]==AB[b][1])&&(AB[a][1]==AB[b][0])))
      |                        ^
a.cc:16:36: error: invalid types 'int[int]' for array subscript
   16 |       if(((AB[a][0]==AB[b][0])&&(AB[a][1]==AB[b][1]))||((AB[a][0]==AB[b][1])&&(AB[a][1]==AB[b][0])))
      |                                    ^
a.cc:16:46: error: invalid types 'int[int]' for array subscript
   16 |       if(((AB[a][0]==AB[b][0])&&(AB[a][1]==AB[b][1]))||((AB[a][0]==AB[b][1])&&(AB[a][1]==AB[b][0])))
      |                                              ^
a.cc:16:60: error: invalid types 'int[int]' for array subscript
   16 |       if(((AB[a][0]==AB[b][0])&&(AB[a][1]==AB[b][1]))||((AB[a][0]==AB[b][1])&&(AB[a][1]==AB[b][0])))
      |                                                            ^
a.cc:16:70: error: invalid types 'int[int]' for array subscript
   16 |       if(((AB[a][0]==AB[b][0])&&(AB[a][1]==AB[b][1]))||((AB[a][0]==AB[b][1])&&(AB[a][1]==AB[b][0])))
      |                                                                      ^
a.cc:16:82: error: invalid types 'int[int]' for array subscript
   16 |       if(((AB[a][0]==AB[b][0])&&(AB[a][1]==AB[b][1]))||((AB[a][0]==AB[b][1])&&(AB[a][1]==AB[b][0])))
      |                                                                                  ^
a.cc:16:92: error: invalid types 'int[int]' for array subscript
   16 |       if(((AB[a][0]==AB[b][0])&&(AB[a][1]==AB[b][1]))||((AB[a][0]==AB[b][1])&&(AB[a][1]==AB[b][0])))
      |                                                                                            ^
a.cc:18:12: error: request for member 'erase' in 'AB', which is of non-class type 'int'
   18 |         AB.erase(AB.begin() + b);
      |            ^~~~~
a.cc:18:21: error: request for member 'begin' in 'AB', which is of non-class type 'int'
   18 |         AB.erase(AB.begin() + b);
      |                     ^~~~~