// MinInt returns the minimum value of an int slice, or 0 if the slice is empty.
MinInt returns the minimum value of an int slice, or 0 if the slice is empty.
// MinInt returns the minimum value of an int slice or 0 if the slice is empty .
func MinInt(vals []int) int {
	if len(vals) == 0 {
		return 0
	} else if len(vals) == 1 {
		return vals[0]
	}
	min := vals[0]
	for _, v := range vals[1:] {
		if v < min {
			min = v
		}
	}
	return min
}
func MinInt ( vals [ ] int ) int { if len ( vals ) == 0 { return 0 } else if len ( vals ) == 1 { return vals [ 0 ] } min := vals [ 0 ] for _ , v := range vals [ 1 : ] { if v < min { min = v } } return min }
MinInt returns the minimum value of an int slice, or 0 if the slice is empty.
MinInt returns the minimum value of an int slice or 0 if the slice is empty .