12 lines
190 B
Go
Raw Permalink Normal View History

2015-10-21 12:15:19 -07:00
package common
// IntInSlice returns true if a is found in the list.
func IntInSlice(a int, list []int) bool {
for _, b := range list {
if b == a {
return true
}
}
return false
}