in reply to finding the position of a particular character in a string

deep3101:

How did you arrive at "6,7,18 or 5,6,17" as acceptable results?

123456789012345678901 # one-based - 6,7,19
THE FOOD IS DELICIOUS
012345678901234567890 # zero-based - 5,6,18

  • Comment on Re: finding the position of a particular character in a string

Replies are listed 'Best First'.
Re^2: finding the position of a particular character in a string
by deep3101 (Acolyte) on Oct 16, 2011 at 15:41 UTC

    Instead of finding out my error you might as well have responded with a solution as others have. And from my end I extend apology for error in counting.

      Instead of finding out my error you might as well have responded with a solution as others have.

      How , by reading your mind?

        I hope that you do have the power to do that Sir, with due respect.