title: How Does Linking a Node to the End of a Linked List Work?
body: <p>What I'm trouble with is not the code, but visualizing this of how its doing its job. I know that first, you have your list (Let's say a list of three elements) and <code>head</code> is pointing to the first element, right? Then you'd have your other pointer, say <code>temp</code>, and its <code>temp-&gt;next = head</code>, so far I get it, but this is where I start to lose it... you'd have it traverse through the list until it reaches an element with a <code>next</code> variable equal to <code>NULL</code>, and then you'd have <code>temp-&gt;next = new_node</code>!! Like how does this work? All I see it doing is making the pointer point to <code>new_node</code> and not making a link to the actual list!</p>