I want to insert a char which saved into a vector, to a string variable.
I'm using this code but I have get error:
result.insert(result.size(), G1[fromPos]);
in this code, G1 is a vector with char type and result is a string variable.
But I get this error:
no instance of overloaded function "std::basic_string<_Elem, _Traits, _Alloc>::insert [with _Elem=char, _Traits=std::char_traits, _Alloc=std::allocator]" matches the argument list argument types are: (size_t, char)
What I have to do to solve this problem?