R/30-api-flexseq-ends.R
peek_back.Rd
Returns the last element without modifying the sequence.
peek_back(x)
A flexseq.
flexseq
Last element, or NULL when x is empty.
NULL
x
Returns the payload element without modifying x.
x <- flexseq("a", "b", "c") peek_back(x) #> [1] "c" peek_back(flexseq()) #> NULL