CodePudding user response:
Find find sometimes will return a negative value, such as - 95-124, not 1CodePudding user response:
You wide character is to be used for processing, string wstring, or directly with wstringFor example
# include & lt; Iostream>
# include & lt; Codecvt>
using namespace std;
Int main (void)
{
Wstring_convert & lt; Codecvt_utf8 & lt; Would be & gt;> Conv.
String s="who am I? "\ n is wide string;
Wstring ss=conv. From_bytes (s);//is converted into a wide string
Cout & lt;
Wstring ws=L "who am I? "\ n is wide string;//directly with wide string literals
Cout & lt;
return 0;
}
CodePudding user response:
Recommend unicode. His code range is consistent, not as utf8, one or two bytes to express one character at a time, unicode is always 2 bytes to express one character at a time,
CodePudding user response: