We are given a string, say, "itiswhatitis"
and a substring, say, "is"
.
I need to find the index of 'i'
when the string "is"
occurs a second time in the original string.
String.indexOf("is")
will return 2 in this case. I want the output to be 10 in this case.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…