std::wmemcmp (3) - Linux Man Pages
Defined in header <cwchar>
int wmemcmp( const wchar_t* lhs, const wchar_t* rhs, std::size_t count );
Compares the first count wide characters of the wide character arrays pointed to by lhs and rhs. The comparison is done lexicographically.
The sign of the result is the sign of the difference between the values of the first pair of wide characters that differ in the arrays being compared.
If count is zero, the function does nothing.
lhs, rhs - pointers to the wide character arrays to compare
count - number of wide characters to examine
Negative value if the value of the first differing wide character in lhs is less than the value of the corresponding wide character in rhs: lhs precedes rhs in lexicographical order.
0 if all count wide characters of lhs and rhs are equal.
Positive value if the value of the first differing wide character in lhs is greater than the value of the corresponding wide character in rhs: rhs precedes lhs in lexicographical order.
This function is not locale-sensitive and pays no attention to the values of the wchar_t objects it examines: nulls as well as invalid wide characters are compared too.
// Run this code