You want us to do your homework... It's not a good thing... As for your question just use String classes and it's methods to do what you need. There is a lot of methods that can help you to accomplish your thing.
Never try to be a hard-worker. Be a smart-worker.
My Blog
but there are � a) what's the index of X (starting at index i) b) break the string into pieces, using X as a delimiter c) what's the character at index i
any could be used to answer your question in several lines of code (or one line, if obfuscation is your cup of tea)
Bill Shirley - bshirley - frazerbilt.com
if (Posts < 30) you.read( JavaRanchFAQ);