Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<stdio.h>
- #include<string.h>
- #include<wchar.h>
- #include<locale.h>
- int main(){
- setlocale(LC_CTYPE, "");
- wchar_t text[200];
- fgetws(text, 200, stdin);
- wchar_t* buffer;
- wchar_t* pch = wcstok(text, L" -,", &buffer);
- while (pch != NULL){
- wprintf(L"%ls\n", pch);
- pch = wcstok(text, L" -,", &buffer);
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement