Final answer:
The main function of computer memory is to facilitate the execution of programs by storing both the program and the data used by the program, involving encoding, storage, and retrieval.
Step-by-step explanation:
The main function of computer memory is best described by statement 3: Computer memory facilitates the execution of programs by storing both the program and the data that is being used by a program. Memory acts as a critical component in the information processing system of a computer, similar to how we process memories in the human brain. It involves the encoding of information, the storage of this information, and the eventual retrieval of the information for use in various tasks and processes.
Computer memory can be divided into different types, typically categorized as short-term memory (or working memory) and long-term memory. Short-term memory temporarily holds data and instructions that the computer is currently using, which allows for quick access and processing. Long-term memory, on the other hand, stores data and instructions that are not immediately needed but that may be required in the future, much like saving a document on a computer's hard drive.