我在Windows控制台中输出Unicode字符时遇到了问题。我正在使用Windows XP和带mingw32-g ++编译器的Code Blocks 12.11。
使用C或C ++在Windows控制台中输出Unicode字符的正确方法是什么?
这是我的C ++代码:
#include <iostream>
#include <string>
using namespace std;
int main()
{
cout << "šđč枊ĐČĆŽ" << endl; // doesn't work
string s = "šđč枊ĐČĆŽ";
cout << s << endl; // doesn't work
return 0;
}
感谢您的提前帮助。 :)