Node of a singly linked list; stores value and the next link.
Time O(1), Space O(1)
Create a list node.
Element value to store.
New node instance.
Get the next node.
Next node or undefined.
Set the next node.
void
Element payload getter.
Element value.
Element payload setter.
New value.
Node of a singly linked list; stores value and the next link.
Remarks
Time O(1), Space O(1)