Answer the question
In order to leave comments, you need to log in
How to write Cyrillic alphabet to file via fstream?
VS 2019, C++ 20.
I tried a lot of options, I just can't write char / string with Cyrillic to a file.
I get something similar from broken bytes ( Encoding in UTF-8 text editor)
Each character is 2 bytes, broken characters are dw0, dw1
�w�w�w�w�wy1diq�w�wy�w�w�w�w�w�w�w�w
РwРwРwРwСwy1diqРwСwyРwРwРwРwСwРwСwСw,yСw
locale loc("ru-RU"); fout.imbue(loc);
vector<char> decode = efi.decrypt(enc);
fout.open("3.txt");
for (int i = 0; i < decode.size(); i++)
fout << decode[i];
fout.close();
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question