hi there
i would really appreciate some help here. i am trying to count the number of sentences in a paragraph.By doing this i count the number of fullstops and then that is equavilent to the number of sentences. I think i got the idea but i can't get the program to work ....please help
this is what i got:
#include <stdio.h>
#define max_char 100
main(){
char para[max_char];
int len_sent,i,;
printf("Please enter a paragraph\n");
fflush(stdin);
gets(para);
len_sent = strlen(para);
for(i=0;i<len_sen;i++){
if(para[i]=='.'){
printf("the number of sentences are: %d)<--I NEED HELP HERE TO COUNT THE NUMBER of FULLSTOPS(.)
}
}