What should I do if I want to split the characters of any string considering gaps and no gaps?
For example, if I have the string My Names James I want each character individually like this: M y n a m e s etc.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You mean this?
Also if you would like to get the chars of the string you could do this:
Now you just need a loop to iterate the characters and do whatever you want with them.
Here a link to the java API documentation there you can find information about the String class.
http://download.oracle.com/javase/6/docs/api/
I hope this was useful to you.