The Stack

The Stack is the fundamental underpinning of how memory works. It is complicated but you must understand it to move forward. We are going to watch a few videos until it makes sense. I will make my own someday.

This explains the stack as a data structure:

This explains stack for memory:

And this finally explains what the hell it all means in regards to how programs work:

Function call basics:

Important Stack Notes:

  • Conceptual, does not exist as a clearly defined place
  • Last in, first off data structure (LIFO)
  • Push on, pop off
  • Stack grows from higher to lower memory addresses
    • Saying the stack grows up or down does not specify towards high or low addresses and can be confusing
    • In this course, stack grows DOWN towards LOWER memory addresses.


  • Submit text discussing anything that you struggled with and didn't understand, and what you did to overcome that problem. If you still don't understand, tell us what specifically you did not understand.