code: func (l *list) FindIndex(pred func(interface{}) bool) int {
  	curr := l
  	idx := 0
  	for {
  		if pred(curr.head) {
  			return idx
  		}
  		tail, _ := curr.Tail()
  		if tail.IsEmpty() {
  			return -1
  		}
  		curr = tail.(*list)
  		idx += 1
  	}
  }
docs: // FindIndex applies the predicate function to the list and returns the index
  // of the first item which matches or -1 if there is no match.