Posted By:
paresh_bhatia
Posted On:
Monday, November 12, 2001 10:50 PM
String str = "this is a text";
char temp;
int word_count=0,avowel_count=0,evoel_cont=0;
for(int i=0;i
temp= str.chatAt(i);
if(temp=='a')
avowel_count++;
}else if(temp=='e')
evowel_count++;
}//similarly for other vowels
if(Character.isWhitespace(temp)) {
word_count++;
}