:
// ContainsString 判断切片中是否包含某个字符串 func ContainsString(slice []string, target string) bool { for _, s := range slice { if s == target { return true } } return false }