VS项目出现未定义标识符to_string

因为string是标准库定义的,发现写#include,只需按照下面方法做即可。

方法1:可以直接包含 using namespace std;

方法2(推荐):使用using std::string;

你可能感兴趣的:(c++,开发语言)