2020-07-26 17:09:05 +08:00
|
|
|
package mathx
|
|
|
|
|
|
2021-02-21 20:47:01 +08:00
|
|
|
// MaxInt returns the larger one of a and b.
|
2025-05-22 23:19:13 +08:00
|
|
|
// Deprecated: use builtin max instead.
|
2020-07-26 17:09:05 +08:00
|
|
|
func MaxInt(a, b int) int {
|
2025-05-22 23:19:13 +08:00
|
|
|
return max(a, b)
|
2020-07-26 17:09:05 +08:00
|
|
|
}
|
|
|
|
|
|
2021-02-21 20:47:01 +08:00
|
|
|
// MinInt returns the smaller one of a and b.
|
2025-05-22 23:19:13 +08:00
|
|
|
// Deprecated: use builtin min instead.
|
2020-07-26 17:09:05 +08:00
|
|
|
func MinInt(a, b int) int {
|
2025-05-22 23:19:13 +08:00
|
|
|
return min(a, b)
|
2020-07-26 17:09:05 +08:00
|
|
|
}
|