File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

StringBuffer confusion ?

 
sharon daze
Greenhorn
Posts: 16
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello all ,

how i can increase a value of StringBuffer.
For example if i have "A" inside StringBuffer element then how i can increment it to next letter.

Thanks & Regards
Sharon
 
Devaka Cooray
ExamLab Creator
Marshal
Pie
Posts: 4116
195
Chrome Eclipse IDE Google App Engine IntelliJ IDE jQuery Postgres Database Tomcat Server
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
sharon daze wrote:how i can increase a value of StringBuffer


What do you mean by increasing the value of StringBuffer? Did you mean converting from A to B, C to D, and so on? In that case, how if you increase the 'char' value of each letter in the string.




Cheers,

Devaka.
 
fred rosenberger
lowercase baba
Bartender
Pie
Posts: 12015
24
Chrome Java Linux
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If your stringBuffer contained "Hello. My name is Inigo Montoya.", what would you increment this to?

Further, I don't think this is a well defined problem, especially since different character sets may not have letters in the same order, or consecutive letters stored as consecutive integers. And what would you increment a 'z' to?

Can you define the problem better? Tell us exactly what you want - or if this is a homework assignment, give us the EXACT and COMPLETE text of it, and we can perhaps steer you better.

 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic