CST 334 - Week 3
This week was about memory management, which, honestly, was hard to understand. I had some ideas about how it works from when I learned programming and also in the architecture course, but that was some time ago. Now, after reading it again, it’s more confusing than helpful. However, what I understand about how memory works is that it’s used to store data, code, instructions, and more. The main memory is one type of memory that allows fast data processing, but it has a limited size and is cleared when it's no longer needed. The purpose of memory management is to allocate the required memory for each program to run and also to protect the memory of other processes while this happens. For programs, memory is stored in locations to be read and to hold variables and arguments. In some programming languages, memory allocation is done automatically, but in others like C, you can manually allocate memory and also free it when it's no longer necessary. According to the book, allocation...