T
thobiasvakayil
I have a problem like this.
How to handle \x0 character inside a string.
Eg:-
#include <string>
#include <iostream>
int main()
{
string str("abcdef\x0 xyz");
cout << "length =" << str.length() << endl;
cout << "string=" << str << endl;
return 0;
}
The output of this program is as follows :
length =6
string=abcdef
But I have to get the output as :
abcdef xyz
Can somebody help ?
Thanks in advance
Regards,
Thobias
How to handle \x0 character inside a string.
Eg:-
#include <string>
#include <iostream>
int main()
{
string str("abcdef\x0 xyz");
cout << "length =" << str.length() << endl;
cout << "string=" << str << endl;
return 0;
}
The output of this program is as follows :
length =6
string=abcdef
But I have to get the output as :
abcdef xyz
Can somebody help ?
Thanks in advance
Regards,
Thobias