Write a program that prints its input one word per line.
2013-09-19 09:38
726 查看
#include <stdio.h> #define State '\n' void main() { int Juge=0;/*only one space*/ int c=0; while((c=getchar())!=EOF) { if(c==' '||c=='\t'||c=='\b') { if(Juge==1) { putchar(State); Juge=0; } } else { putchar(c); Juge=1; } } }
I Love U I Love U
相关文章推荐
- Write a program to copy its input to its output, replacing each string of one or more blanks by a single blank.
- Write a program that prints the numbers from 1 to 100,but for multiples of three print “Fizz” inste
- Write a program to copy its input to its output, replacing each tab by \t, each backspace by \b, and each backslash by \\. This makes tabs and backspa
- Description 7 3 8 8 1 0 2 7 4 4 4 5 2 6 5 (Figure 1) Figure 1 shows a number triangle. Write a program that calculates the highes
- Issue 111( Most important discoveries or creation are accidental; it is usually while seeking the answer to one question that
- Write a program that will help elementary school pupils practice math
- Write a program that will help elementary school pupils practice math
- Wrap persistent words count one line in print program
- mac supervisor error :Another program is already listening on a port that one of our HTTP servers is
- Write a program that will help elementary school pupils practice math
- reason=>"Expected one of #, input, filter, output at line 1, column 1 (byte 1) after "}
- Write a function that generates one of 3 numbers according to given probabilities
- 7 3 8 8 1 0 2 7 4 4 4 5 2 6 5 (Figure 1) Figure 1 shows a number triangle. Write a program that calc
- Write a program that will help elementary school pupils practice math
- VB文件系统编程中的input/line input,print和write语句相同点和区别
- Write a routine that prints out a 2-D array in spiral order
- [20160704]Addition program that use JOptionPane for input and output
- Write a program that gives count of common characters presented in an array of strings..(or array of
- Analyzing Linux kernel crash dumps with crash - The one tutorial that has it all
- 英语口语练习十五之If there is one thing that...me, it's... (如果有什么使我……的话,那就是)法