Table of contents
1. What are dynamic data structures?2. Stack vs heap memory
2.1 Stack memory
2.2 Heap memory
3. Dynamic memory allocation functions
3.1 The malloc function
3.2 The calloc function
3.3 The realloc function
3.4 The free function
4. Memory leaks and how to avoid them
5. Dynamic arrays
5.1 Implementing a simple dynamic array
6. Introduction to linked lists
6.1 Why use linked lists?
6.2 The node structure
6.3 Creating a complete linked list implementation
7. Visualising linked lists
7.1 Inserting at the beginning
8. Comparing arrays and linked lists
9. Common mistakes with dynamic data structures
9.1 Forgetting to check for NULL
9.2 Using memory after freeing
9.3 Freeing memory twice
10. Practical exercise
11. Summary
