shithub: mc

ref: 314b2c1651a2c946a3d9e3ccdd9fff739e603b2b
dir: /libstd/extremum.myr/

View raw version
pkg std =
	generic min	: (a : @a::numeric, b : @a::numeric  -> @a::numeric)
	generic max	: (a : @a::numeric, b : @a::numeric  -> @a::numeric)
;;

generic min = {a, b
	if a < b
		-> a
	else
		-> b
	;;
}

generic max = {a, b
	if a > b
		-> a
	else
		-> b
	;;
}