git-lfs/tools/math.go
Taylor Blau e6eb985b0a tools: 💅
2016-11-08 18:50:52 -07:00

20 lines
266 B
Go

package tools
// MinInt returns the smaller of two `int`s, "a", or "b".
func MinInt(a, b int) int {
if a < b {
return a
}
return b
}
// MaxInt returns the greater of two `int`s, "a", or "b".
func MaxInt(a, b int) int {
if a > b {
return a
}
return b
}