这个网页中的代码,我复制下来之后粘贴在VC++,出现了这样的错误。怎么修改才能在VC++中运行呢?希望能把修改好之后的代码发出来。
--------------------Configuration: Cpp1 - Win32 Debug--------------------
Compiling...
Cpp1.cpp
c:\users\administrator\desktop\cpp1.cpp(46) : error C2065: 'assert' : undeclared identifier
c:\users\administrator\desktop\cpp1.cpp(599) : error C2679: binary '<<' : no operator defined which takes a right-hand operand of type 'class std::basic_string,class std::allocator >' (or there is no acceptab
le conversion)
c:\users\administrator\desktop\cpp1.cpp(601) : error C2679: binary '>>' : no operator defined which takes a right-hand operand of type 'class std::basic_string,class std::allocator >' (or there is no acceptab
le conversion)
c:\users\administrator\desktop\cpp1.cpp(602) : error C2676: binary '==' : 'class std::basic_string,class std::allocator >' does not define this operator or a conversion to a type acceptable to the predefined
operator
c:\users\administrator\desktop\cpp1.cpp(602) : error C2676: binary '==' : 'class std::basic_string,class std::allocator >' does not define this operator or a conversion to a type acceptable to the predefined
operator
执行 cl.exe 时出错.
Cpp1.exe - 1 error(s), 0 warning(s)