linux下string类型报错

提示:string 不是一个类型名

#include <iostream>       
    #include <string>     
    using namespace std;  
    int       main()       
    {       
                    string       temp       =       "fdsafdas";       
                    cout       < <       temp       < <       endl;       
    }
    注意头文件以及命名空间。
 

猜你喜欢

转载自blog.csdn.net/roshy/article/details/84308290