求指教,求鞭笞,关于string::size_type;
int main(){string st("abcdefghijklmn");
if(st.size()==0)
.......
}
这是我在书上看到的一段,我很疑惑size()成员函数的返回值是string::size_type,这个应该是类类型,怎么和int的0进行比较呢。
求指教啊。。。。。
![](images/smilies/tk/tk06.gif)
#include "afx.h" typedef unsigned int wp231957; int _tmain(int argc, _TCHAR* argv[]) { wp231957 test; test=123456; printf("%d",test); return 0; }