why does this work
Code:
printf ("Please enter a sentence");
while ((ch = getchar()) != '.') {   //i know that '\n' would terminate on new line character
if (ch == '.' || ch == '!' || ch == '?') 
break; 
sentence[i++] = ch;
but this doesnt?
Code:
printf ("Please enter a sentence");
while ((ch = getchar()) != '.' || ch != '!' || ch != '?') {
sentence[i++] = ch;
the scond code doesn't teminate