Skip to Main Content

Java Programming

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

how to count words in a string

807607Oct 16 2006 — edited Oct 16 2006
hey guyz!! i have to write a program which reads the prefix(entered by the user) form a string and returns the number of times that prefix occured in the whole string or line!!
so i was wondering how would read every single word in a string !!! string is supposed to be entered by the user too!!! thx for the help!!
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 13 2006
Added on Oct 16 2006
18 comments
868 views