i would like to delete all files in a directory, is there any function can help with this?
thank you for helping~~
i would like to delete all files in a directory, is there any function can help with this?
thank you for helping~~
Look up findfirst() findnext() and remove()
You might take a look at Salem'sdirectory walker.
And when removing a directory, remember to delete all of the files within it before attempting to remove the directory itself (if there are subdirectories, these of course must be deleted before the parent is).
Code:#include <cmath> #include <complex> bool euler_flip(bool value) { return std::pow ( std::complex<float>(std::exp(1.0)), std::complex<float>(0, 1) * std::complex<float>(std::atan(1.0) *(1 << (value + 2))) ).real() < 0; }