Advertisement
Guest User

Untitled

a guest
May 20th, 2019
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.36 KB | None | 0 0
  1. #include <fstream>
  2. #include <iostream>
  3. #include <filesystem>
  4. namespace fs = std::filesystem;
  5.  
  6. int main()
  7. {
  8.     fs::create_directories("sandbox/a/b");
  9.     std::ofstream("sandbox/file1.txt");
  10.     std::ofstream("sandbox/file2.txt");
  11.     for(auto& p: fs::directory_iterator("sandbox"))
  12.         std::cout << p.path() << '\n';
  13.     fs::remove_all("sandbox");
  14. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement