type/range
check for a range
Calling Sequence
Parameters
Description
Examples
type(expr, 'range')
type(expr, 'range'(typespec))
type(expr, '`..`')
type(expr, '`..`'(typespec))
expr
-
any expression
typespec
any type expression
This function returns true if expr is of type range, and false otherwise.
An expression of type range (also called type `..`) has two operands, the expression on the left-hand side and the expression on the right-hand side. These two operands are separated by an ellipsis (..) .
The optional parameter typespec may be used to specify a type that the operands of expr must also satisfy. The typespec parameter may be used with either form (range or `..`) of the type.
type⁡a..b,`..`
true
type⁡1..4,`..`
type⁡i..j,range
type⁡1..n,range
type⁡1..n,range⁡posint
false
type⁡1..10,range⁡posint
See Also
plot/range
range
type
type/Range
Download Help Document