Version: 1.15

# Range functions

A set of functions establish relationships between single scalar values and ranges of such values. All functions take two arguments and return `true` if the relationship between the argument holds, or `false` otherwise.

A scalar value must be of the following type:

• number
• date
• time
• date-time
• days-time-duration
• years-months-duration

## before()​

• parameters:
• `point1`, `point2`: any
• or `range`: range, `point`: any
• or `point`: any, `range`: range
• or `range1`, `range2`: range
• result: boolean
``before(1, 10)// truebefore(10, 1)// falsebefore(1, [2..5])// truebefore([1..5], 10)// truebefore([1..5], [6..10])// truebefore([1..5),[5..10])// true``

## after()​

• parameters:
• `point1`, `point2`: any
• or `range`: range, `point`: any
• or `point`: any, `range`: range
• or `range1`, `range2`: range
• result: boolean
``after(10, 1)// trueafter(1, 10)// falseafter(12, [2..5])// true([1..5], 10)// falsebefore([6..10], [1..5])// truebefore([5..10], [1..5))// true``

## meets()​

• parameters:
• `range1`: range
• `range2`: range
• result: boolean
``meets([1..5], [5..10])// truemeets([1..3], [4..6])// falsemeets([1..3], [3..5])// truemeets([1..5], (5..8])// false``

## met by()​

• parameters:
• `range1`: range
• `range2`: range
• result: boolean
``met by([5..10], [1..5])// truemet by([3..4], [1..2])// falsemet by([3..5], [1..3])// truemet by((5..8], [1..5))// falsemet by([5..10], [1..5))// false``

## overlaps()​

• parameters:
• `range1`: range
• `range2`: range
• result: boolean
``overlaps([5..10], [1..6])// trueoverlaps((3..7], [1..4])// trueoverlaps([1..3], (3..6])// falseoverlaps((5..8], [1..5))// falseoverlaps([4..10], [1..5))// treu``

## overlaps before()​

• parameters:
• `range1`: range
• `range2`: range
• result: boolean
``overlaps before([1..5], [4..10])// trueoverlaps before([3..4], [1..2])// falseoverlaps before([1..3], (3..5])// falseoverlaps before([1..5), (3..8])// trueoverlaps before([1..5), [5..10])// false``

## overlaps after()​

• parameters:
• `range1`: range
• `range2`: range
• result: boolean
``overlaps after([4..10], [1..5])// trueoverlaps after([3..4], [1..2])// falseoverlaps after([3..5], [1..3))// falseoverlaps after((5..8], [1..5))// falseoverlaps after([4..10], [1..5))// true``

## finishes()​

• parameters:
• `point`: any, `range`: range
• or `range1`, `range2`: range
• result: boolean
``finishes(5, [1..5])// truefinishes(10, [1..7])// falsefinishes([3..5], [1..5])// truefinishes((1..5], [1..5))// falsefinishes([5..10], [1..10))// false``

## finished by()​

• parameters:
• `range`: range, `point`: any
• or `range1`, `range2`: range
• result: boolean
``finishes by([5..10], 10)// truefinishes by([3..4], 2)// falsefinishes by([3..5], [1..5])// truefinishes by((5..8], [1..5))// falsefinishes by([5..10], (1..10))// true``

## includes()​

• parameters:
• `range`: range, `point`: any
• or `range1`, `range2`: range
• result: boolean
``includes([5..10], 6)// trueincludes([3..4], 5)// falseincludes([1..10], [4..6])// trueincludes((5..8], [1..5))// falseincludes([1..10], [1..5))// true``

## during()​

• parameters:
• `point`: any, `range`: range
• or `range1`, `range2`: range
• result: boolean
``during(5, [1..10])// trueduring(12, [1..10])// falseduring(1, (1..10])// falseduring([4..6], [1..10))// trueduring((1..5], (1..10])// true``

## starts()​

• parameters:
• `point`: any, `range`: range
• or `range1`, `range2`: range
• result: boolean
``starts(1, [1..5])// truestarts(1, (1..8])// falsestarts((1..5], [1..5])// falsestarts([1..10], [1..10])// truestarts((1..10), (1..10))// true``

## started by()​

• parameters:
• `range`: range, `point`: any
• or `range1`, `range2`: range
• result: boolean
``started by([1..10], 1)// truestarted by((1..10], 1)// falsestarted by([1..10], [1..5])// truestarted by((1..10], [1..5))// falsestarted by([1..10], [1..10))// true``

## coincides()​

• parameters:
• `point1`, `point2`: any
• or `range1`, `range2`: range
• result: boolean
``coincides(5, 5)// truecoincides(3, 4)// falsecoincides([1..5], [1..5])// truecoincides((1..5], [1..5))// falsecoincides([1..5], [2..6])// false``