C examples for wctype.h:iswcntrl
function
<cwctype> <wctype.h>
Check if wide character is a control character
int iswcntrl (wint_t c);
Parameter | Description |
---|---|
c | Wide character to be checked |
A non zero value (i.e., true) if c is a control character. Zero (i.e., false) otherwise.
#include <stdio.h> #include <wctype.h> int main ()//ww w . j a v a2 s . c om { int i=0; wchar_t str[] = L"this is a test. first line \n second line \n"; while (!iswcntrl(str[i])) { putwchar (str[i]); i++; } return 0; }