#include <cstdlib> _itoa(num, buf, 2); 打印buf既是二进制 转载于:https://www.cnblogs.com/xpylovely/p/10977777.html