View source: R/40-priority_queue-queue-ops.R
| peek_min | R Documentation |
Returns the element at the minimum priority without modifying the queue.
peek_min(x)
x |
A |
Ties are stable: when multiple elements share minimum priority, this returns the earliest element in queue order.
Element at minimum priority, or NULL when x is empty.
x <- priority_queue("a", "b", "c", priorities = c(2, 1, 1))
peek_min(x)
peek_min(priority_queue())
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.