Module:Number

local p = {}

- -- function: inRange(min: number, max: number, compare: number, inclusive?: boolean) -- -- Checks if `compare` is in the range of `min` or `max`. - function p.inRange(min, max, compare, inclusive) inclusive = inclusive ~= false

if inclusive then return compare >= min and compare <= max else return compare > min and compare < max end end

return p