c++删除文件

#include <iostream>
#include <stdio.h>
using namespace std;

int main()
{
    int error = remove("/share/zheng.txt");
    if (0 == error)
    {
        cout << "OK" << endl;
    }
    else
    {
        cout << "FILE\n";
    }
   // system("pause");
    return 0;

}

おすすめ

転載: blog.csdn.net/mp295345033/article/details/50125339
おすすめ