// StringsBytesE creates a new slice with the results of calling the provided function on every element in the given array.
// Returns an error if one of the function calls fails.
StringsBytesE creates a new slice with the results of calling the provided function on every element in the given array.
Returns an error if one of the function calls fails.
// StringsBytesE creates a new slice with the results of calling the provided function on every element in the given array . // Returns an error if one of the function calls fails .
func StringsBytesE(s []string, f func(s string) (byte, error)) (bytes.Bytes, error) {
	m := bytes.Bytes(make([]byte, len(s)))
	var err error
	for i, v := range s {
		m[i], err = f(v)
		if err != nil {
			return nil, err
		}
	}
	return m, nil
}
func StringsBytesE ( s [ ] string , f func ( s string ) ( byte , error ) ) ( bytes . Bytes , error ) { m := bytes . Bytes ( make ( [ ] byte , len ( s ) ) ) var err error for i , v := range s { m [ i ] , err = f ( v ) if err != nil { return nil , err } } return m , nil }
StringsBytesE creates a new slice with the results of calling the provided function on every element in the given array.
StringsBytesE creates a new slice with the results of calling the provided function on every element in the given array .