#include <iostream>
#include <filesystem>
namespace fs = std::filesystem;
using namespace std;
int main()
{
fs::path p = fs::current_path();
cout << p << endl;
string p_string = p.string();
cout << p_string << endl;
return 0;
}
When printing out 'p' the path is shown as this.
"C:\\Users\\tp\\source\\repos\\test"
But after the conversion to a string it comes out like this.
C:\Users\tp\source\repos\test
Is there a way I could retain the original form of the path?