Elixir v1.2.6 Range
Defines a range.
A range represents a discrete number of values where the first and last values are integers.
Ranges can be either increasing (first <= last) or decreasing (first > last). Ranges are also always inclusive.
A Range is represented internally as a struct. However,
the most common form of creating and matching on ranges
is via the ../2
macro, auto-imported from Kernel:
iex> range = 1..3
1..3
iex> first..last = range
iex> first
1
iex> last
3
Summary
Types
Functions
Creates a new range.