diff --git a/proglabs/lab6/1.c b/proglabs/lab6/1.c new file mode 100644 index 0000000..f724da3 --- /dev/null +++ b/proglabs/lab6/1.c @@ -0,0 +1,14 @@ +#include + +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; +} diff --git a/proglabs/lab6/tmp.out b/proglabs/lab6/tmp.out index 7d59dd1..2b05db1 100755 Binary files a/proglabs/lab6/tmp.out and b/proglabs/lab6/tmp.out differ