BUGBUG 1、Use of undeclared identifier 'M_PI' 1、Use of undeclared identifier ‘M_PI’ C++11版本中导入cmath并不能解决此问题,需要在#include 之前添加#define _USE_MATH_DEFINES,如下: #define _USE_MATH_DEFINES #include <cmath> 加载M_PI成功。