Range.firstIter

Returns an iterator pointing to the first element of the range.

Arguments

None

Return values

iterator
pointing to the first element.

Complexity

Constant

Example

"sl/redBlackTree" useFile rb: ((1 "ONE") (2 "TWO") (10 "TEN") (50 "FIFTY")) makeRedBlackTree; r: 2 20 rb.makeRange.bound; it: r.firstIter; [ it r.endIter = ~ ] [ it.get print LF print it.next !it ] while
Output:
{ key: 2; value: "TWO"; } { key: 10; value: "TEN"; }