Language: C++

#include<iostream>
#include<string>
#include<vector>
using namespace std;
int h,w,ki,hi,yi,b;
int ch[30];
vector<string> a(100);
int main(){
  for(int i=0;i<30;i++)ch[i]=0;
  cin>>h>>w;ki=0;yi=0;hi=0;a=0
  for(int i=0;i<h;i++){
    cin>>a[i];
    for(int j=0;j<w;j++){
      ch[a[i][j]-'a']++;
    }  
  }
  for(int i=0;i<30;i++){
    if(ch[i]%2==1)ki++;
    if(ch[i]%2==0 && ch[i]%4!=0 && ch[i]>0)hi++;
    if(ch[i]%4==0 && ch[i]>0)yi++;
  }
  if((h*w)%2==1){
    if(ki==1 && yi<=(h/2)*(w/2) && hi<)cout<<"Yes"<<endl;
    else cout<<"No"<<endl;
  }else{
    if(h%2==0 && w%2==0){
      if(ki==0 && hi==0 )cout<<"Yes"<<endl;
      else cout<<"No"<<endl;
    }else{
      if(h%2==1)b=h else b=w;
      if(ki==0 && hi<=b/2 )cout<<"Yes"<<endl;
      else cout<<"No"<<endl;
    }
  }
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:10:30: error: no match for 'operator=' (operand types are 'std::vector<std::__cxx11::basic_string<char> >' and 'int')
   10 |   cin>>h>>w;ki=0;yi=0;hi=0;a=0
      |                              ^
In file included from /usr/include/c++/14/vector:72,
                 from a.cc:3:
/usr/include/c++/14/bits/vector.tcc:210:5: note: candidate: 'std::vector<_Tp, _Alloc>& std::vector<_Tp, _Alloc>::operator=(const std::vector<_Tp, _Alloc>&) [with _Tp = std::__cxx11::basic_string<char>; _Alloc = std::allocator<std::__cxx11::basic_string<char> >]'
  210 |     vector<_Tp, _Alloc>::
      |     ^~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/vector.tcc:211:42: note:   no known conversion for argument 1 from 'int' to 'const std::vector<std::__cxx11::basic_string<char> >&'
  211 |     operator=(const vector<_Tp, _Alloc>& __x)
      |               ~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
In file included from /usr/include/c++/14/vector:66:
/usr/include/c++/14/bits/stl_vector.h:766:7: note: candidate: 'std::vector<_Tp, _Alloc>& std::vector<_Tp, _Alloc>::operator=(std::vector<_Tp, _Alloc>&&) [with _Tp = std::__cxx11::basic_string<char>; _Alloc = std::allocator<std::__cxx11::basic_string<char> >]'
  766 |       operator=(vector&& __x) noexcept(_Alloc_traits::_S_nothrow_move())
      |       ^~~~~~~~
/usr/include/c++/14/bits/stl_vector.h:766:26: note:   no known conversion for argument 1 from 'int' to 'std::vector<std::__cxx11::basic_string<char> >&&'
  766 |       operator=(vector&& __x) noexcept(_Alloc_traits::_S_nothrow_move())
      |                 ~~~~~~~~~^~~
/usr/include/c++/14/bits/stl_vector.h:788:7: note: candidate: 'std::vector<_Tp, _Alloc>& std::vector<_Tp, _Alloc>::operator=(std::initializer_list<_Tp>) [with _Tp = std::__cxx11::basic_string<char>; _Alloc = std::allocator<std::__cxx11::basic_string<char> >]'
  788 |       operator=(initializer_list<value_type> __l)
      |       ^~~~~~~~
/usr/include/c++/14/bits/stl_vector.h:788:46: note:   no known conversion for argument 1 from 'int' to 'std::initializer_list<std::__cxx11::basic_string<char> >'
  788 |       operator=(initializer_list<value_type> __l)
      |                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
a.cc:11:15: error: 'i' was not declared in this scope; did you mean 'yi'?
   11 |   for(int i=0;i<h;i++){
      |               ^
      |               yi
a.cc:23:39: error: expected primary-expression before ')' token
   23 |     if(ki==1 && yi<=(h/2)*(w/2) && hi<)cout<<"Yes"<<endl;
      |                                       ^
a.cc:30:20: error: expected ';' before 'else'
   30 |       if(h%2==1)b=h else b=w;
      |                    ^~~~~
      |                    ;