• Post Reply Bookmark Topic Watch Topic
  • New Topic

nextindex of

 
shinu pillai
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
in java how we take next index of string on single line
 
Ernest Friedman-Hill
author and iconoclast
Sheriff
Posts: 24213
35
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Use one of the two-argument versions of indexOf(). The first time you call it, pass "0" as the second argument. The second time you call it, pass the result from that first call plus the length in characters of the first argument; i.e.,

 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!