在vscode的wsl2终端输入 g++ -g –Wall –o test test.cpp结果报错g++: error: –Wall: No such file or directoryg++: error: –o: No such file or directoryg++: error: test: No such file or directory请问是什么原因
–Wall 和-o前面的-需要用英文的-,你用成中文的了
g++ -g -Wall -o test test.cpp
环境没配好。检查一下环境。