Hi Experts,

Seems a trivial problem, but unable to find the right imports to do this..
Want to search for a substring in a huge string ( output of a exec.command)
and get the index for every occurrence of that substring.  I used Index and
LastIndex, both give first and last, but am looking for IndexNext kind of
till the last occurrence....

For example : "Hello this is Golang program Golang has a variety of import
utilities.I like to code in Golang"

In the above example, I want an API which will return each occurrence of
Golang


Sharanya

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/CAGOT8arzm9OeP0dyq58z2%3Dh3ePom5J_j_YvUqG0HP6TwTNwjZQ%40mail.gmail.com.

Reply via email to