new file: proglabs/lab6/1.c

This commit is contained in:
2025-11-04 16:30:49 +07:00
parent 93cd8d90ae
commit 09acaeef51
2 changed files with 14 additions and 0 deletions
+14
View File
@@ -0,0 +1,14 @@
#include <stdio.h>
int main() {
int ch,sp,n,s;
sp = n = s = 0;
while((ch = getchar())!='#'){
switch(ch){
case ' ': n++; break;
case '\n': sp++; break;
default: s++; break;
}}
printf("spaces: %d\tnewln: %d\tsymb: %d\n",sp,n,s);
return 0;
}
Binary file not shown.