Singly Linked List definition
- a data structure that contains a head, tail, and lenght property.
- linked list consist of nodes, and each node has a value and a pointer to another node or null.
-only one direction -ONEWAY
+--+---------------------+----------------------------------+ | | Linked List | Arrays | +--+---------------------+----------------------------------+ +--+---------------------+----------------------------------+ | | NO IDX | IDX | +--+---------------------+----------------------------------+ | | | | | | connected via nodes | insertion and deletion | | | w/ a next pointer | can be expensive | +--+---------------------+----------------------------------+ | | sequential access: | direct access: | | | NO random access | quick access at the specific IDX | +--+---------------------+----------------------------------+