16. 宽字符

创建日期:2024-07-11
更新日期:2025-02-01

wchar.cpp

#include <iostream>
#include <cstring>
#include <locale>

int main()
{
    using namespace std;

    setlocale(LC_ALL, "");

    wstring title = L"你好";
    // u16string name = u"Felonia Ripova";
    // u32string car = U"Huber Super Snipe";

    wcout << "title = " << title << endl;
    // wcout << "name = " << name << endl;
    // cout << "car = " << car << endl;
}