Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

regarding strings  RSS feed

 
gayathriy Nandakumar
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi..how do i find index number of one character in a string that uses StringBuffer to store the string???(as StringBuffer has only indexof(String) and not indexOf(char))

StringBuffer codestring=new StringBuffer("abcdefghijklmnopqrstuvwxyz");
int cs=codestring.indexOf(c);
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator


(I'm not sure why you're using a StringBuffer here...)
[ July 13, 2006: Message edited by: Satou kurinosuke ]
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!