1.建立‘.vscode’下的‘c_cpp_properties.json’ 2.在cmd中查看Mingw的路径(gcc -v -E -x c++ -)并粘贴到‘c_cpp_properties.json’中。 可能是C/C++没有启用