mirror of
https://github.com/mindoc-org/mindoc.git
synced 2026-01-23 21:32:19 +08:00
16 lines
146 B
Go
16 lines
146 B
Go
package utils
|
|
|
|
func AbsInt(a int) int {
|
|
if a < 0 {
|
|
return -a
|
|
}
|
|
return a
|
|
}
|
|
|
|
func MinInt(a, b int) int {
|
|
if a < b {
|
|
return a
|
|
}
|
|
return b
|
|
}
|