错误现象:
error C2143: syntax error : missing ';' before '<'
error C2501: 'list' : missing storage-class or type specifiers
error C2059: syntax error : '<'
error C2039: 'iterator' : is not a member of '`global namespace''
error C2238: unexpected token(s) preceding ';'
error C2143: syntax error : missing ';' before '<'
解决方法:
#include <list>
using namespace std;//此句添加
//其他类似错误也应该添加此句
class myclass
{
.........
}