Documentation: What do peek() and peekPriority() return on empty heap
Feuermurmel opened this issue · comments
Feuermurmel commented
I could not find a description on what peek()
and peekPriority()
return when the heap is empty. pop()
has a return type of number | undefined
, and is documented to return undefined
if the heap is emtpy, but peek()
and peekPriority()
both return just number
.