gitee.com/quant1x/num@v0.3.2/internal/functions/find.go (about) 1 package functions 2 3 import "gitee.com/quant1x/num/internal/constraints" 4 5 func Find_Go[T constraints.Float](x []T, a T) int { 6 for i, v := range x { 7 if v == a { 8 return i 9 } 10 } 11 return -1 12 }