Many lectures in this course use memory diagrams to show how objects and variables are laid out on the stack and the heap. This lesson will lay down some groundwork and explain in detail what the stack is for, and how data on the stack is laid out in memory.  


 After completing this lecture you will have learned which data is stored on the stack and what happens when this data goes out of scope. Finally, you will have seen a Stack Overflow exception, and know how to avoid this exception in your own code. 

 If you are already familiar with the internal workings of the stack in the .NET Framework, feel free to skip this lecture.