Answer the question
In order to leave comments, you need to log in
Why doesn't the Russian c++ console work?
Hello. There was a question with the Cyrillic output to the console. Tried this code:
#include <iostream>
#include <clocale>
#include <windows.h>
int main() {
setlocale(LC_ALL,"Rus");
SetConsoleCP(1251);
SetConsoleOutputCP(1251);
cout << "Привет";
return 0;
}
Answer the question
In order to leave comments, you need to log in
This is how I do the Russian language in the console:
int main()
{
setlocale(LC_ALL, "Russian");
}
Another option used. After that, you need to clear the console:
system("chcp 1251");
system("cls");
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question