判断文件夹是否存在
include
include
include
include <Windows.h>
include <stdio.h>
include <direct.h>
include <io.h>
using namespace std;
int main(){
std::string prefix = "./Log/";
if (_access(prefix.c_str(), 0) == -1) //如果文件夹不存在
_mkdir(prefix.c_str()); //则创建
//system("mkdir .\Log");
return 0;
}

浙公网安备 33010602011771号