Function

How do the functions mid() and lenght() work in C++ ???
I do not know such functions in C++.:) They are user-defined functions or member functions of some class.
Last edited on
They are functions from QBasic so they have to be in c++ too .
std::string has a member function called length(). It returns the length of the string.
If you mean mid$ from Basic, then you might want to look at substr() in std::string.
http://www.cplusplus.com/reference/string/string/substr/
Topic archived. No new replies allowed.