Long time no see

This commit is contained in:
2026-02-21 10:47:00 +07:00
parent 0d54fe176e
commit b7df98a55c
198 changed files with 3249 additions and 1 deletions
+22
View File
@@ -0,0 +1,22 @@
#include <stdio.h>
#include <wchar.h>
#include <locale.h>
int main() {
setlocale(LC_ALL, "");
float ch = 0,words = 0,o = 0;
wchar_t x;
while((x = getwchar()) != WEOF){
switch(x){
case ' ':
ch += o;
if(o>0) words++;
o = 0;
break;
default:
o++;
}
}
printf("\nch per word - %.2f\n",ch/words);
return 0;
}