2
0

wcswidth.c 227 B

12345678910
  1. #include <stdio.h>
  2. #include <wchar.h>
  3. int main () {
  4. wchar_t *wcs = L"relibc";
  5. size_t len = wcslen(wcs);
  6. int width = wcswidth(wcs, len);
  7. printf("wcswidth(L\"%ls\", %d) = %d\n", wcs, len, width);
  8. return 0;
  9. }