Concept Flow - Creating a Singly Linked List from Scratch
Start
Create head node with data
Set head.next = nullptr
Add more nodes?
No→Done
Yes
Create new node
Traverse to last node
Set last_node.next = new_node
Repeat Add more nodes?
Start by creating the first node as head. For each new node, traverse to the last node and link the new node at the end. Repeat until no more nodes to add.
