If I write this: charIs('a');
Then I would expect the function to return the number 0.
These are the errors shown in Visual Studio 2019 (Both are for line 17):
Error C3867 'std::vector<char,std::allocator<char>>::size': non-standard syntax; use '&' to create a pointer to member
Error C2446 '<': no conversion from 'unsigned int (__thiscall std::vector<char,std::allocator<char>>::* )(void) noexcept const' to 'uint'
How do I fix these errors while keeping the intended design of the code?
E0289 no instance of constructor "std::vector<_Ty, _Alloc>::vector [with _Ty=char [3], _Alloc=std::allocator<char [3]>]" matches the argument list
E0153 expression must have class type
C2440 'initializing': cannot convert from 'initializer list' to 'std::vector<char [3],std::allocator<_Ty>>'