Hi, In my java program I accepted string from the user and now I want to calculate the length of the string, and then read characters one by one to encrypt it. How to read the characters one by one ? Like Mid$ function in VB.
"As long as there are tests, there will be prayer in public <br />schools."
Joined: Dec 07, 2001
To find the length of string use length() method AND THAN RUN IT IN A for loop fo charter finding perhaps folowin code willhelp:
hope it may help... Arun
Rohit Prakash Khare
Joined: Jun 09, 2002
Thanks Arun, I will sure try.
Joined: Jun 03, 2002
Another approach similar to the $mid is substr(int begpos,int endpos) in a for loop