I am a AD students. I have a question here. does anyone help me?
i am writing a program to get word from text file, which is an eassy. i need to sperate each word and then write to another text file. in the new text file, the word should be one word per line , no numbers or other char such as !, ? and many others, no double or something like that are allow.
i have wrote it, but something is wrong. I get word from text and write to the new text file but in the new text file. i have find the double line. Why does it cause? What's wrong is that?
in the text file
i am a boy. i am 15 years old.
in the new text file
my code is here
if(word[i] == ' ' || word[i]=='\n')
else if (((word[i]>='a') && (word[i]<='z')) || ((word[i]>='A') && (word[i]<='Z')))