char s1[] = "abc", s2[] = "abc";
const char s3[] = "abc", s4[] = "abc", *s5 = "abc", *s6 = "abc";
string s7("abc"), s8("abc");
cout << (s3 == s4) << " " << (s5 == s6) << " " << (s7 == s8) << " " << (s1 == s2) << " ";
输出结果为:
char s1[] = "abc", s2[] = "abc";
const char s3[] = "abc", s4[] = "abc", *s5 = "abc", *s6 = "abc";
string s7("abc"), s8("abc");
cout << (s3 == s4) << " " << (s5 == s6) << " " << (s7 == s8) << " " << (s1 == s2) << " ";
输出结果为: