How to get the size of a wide character in C++

1 Answer

0 votes
#include <iostream>

int main() {
    wchar_t ch = L'ф';
    
    std::cout << sizeof(ch);
}




/*
run:

4

*/

 



answered Nov 27, 2022 by avibootz

Related questions

1 answer 137 views
1 answer 135 views
1 answer 144 views
1 answer 146 views
...