func MaxByDir(a, b int, dir Direction) int {
	if dir == POSITIVE {
		return b
	}
	return a
}
MaxByDir return maxium of a and b sorted by direction
package region
type Direction bool
const (
	POSITIVE Direction = true
	REVERSE  Direction = false
)
func SeqByDir(a, b int, dir Direction) (int, int) {
	if dir == POSITIVE {
		return a, b
	}
	return b, a
}
func MinByDir(a, b int, dir Direction) int {
	if dir == POSITIVE {
		return a
	}
	return b
}