Guest User

Untitled

a guest
Jul 19th, 2018
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1. #include <iostream>
  2. #include <string>
  3. #include <fstream>
  4. #include <cassert>
  5. #include "boost/date_time/gregorian/gregorian.hpp"
  6. using namespace std;
  7. using namespace boost::gregorian;
  8.  
  9. int main() {
  10. date d(from_undelimited_string(string{"20180101"}));
  11. string ext = to_iso_extended_string(d);
  12. assert(ext == "2018-01-01");
  13. for (day_iterator d{start_date}; d <= end_date; ++d) {
  14. ofstream ofs(argv[3] + to_iso_extended_string(*d), std::ofstream::out);
  15. }
  16. }
Add Comment
Please, Sign In to add comment