ROM and RAM and what is their relationship with CPU

Function description:
1. RAM (Random Access Memory),is commonly known as memory. Under normal working state, it can read and write data into the memory at any time, but if the power is cut down, the data stored in the memory will be lost.
For example, the memory of the computer, the memory of the mobile phone, including the cache used in CPU, all belong to RAM.
2. According to the working principle of the memory unit, RAM can be divided into static memory (SRAM) and dynamic memory (DRAM).
ROM (Read only Memory) is commonly known as flash memory. This kind of memory is only readable, unlike RAM, which can be read and written at any time.
3. ROM is stored on a non-volatile chip and the contents of memory can be saved even after shutdown. Therefore, this kind of memory is often used to store system programs or programs with specific functions.
To sum up, RAM refers to the memory of the mobile phone (which can be regarded as the memory of the computer). ROM refers to the memory of the firmware code of the mobile phone (which can be seen as the hard disk of the computer), such as mobile phone operating system, some applications like games.
ROM stores the running instructions used to start the mobile phone. On boot, ROM provides a series of running instructions for the central processing unit (CPU) to test. In the initial test, the RAM location will be checked to confirm its ability to store data.
The relationship between them is a simple metaphor:
For example, CPU is us, ROM is a bookshelf, RAM is a desk, and the app is a book.
When we want to work or study, we first take the books off the bookshelf and put them on the desk to start working or studying.
Similarly, CPU issues instructions to read the app from ROM to run on RAM.Therefore, the speed of APP has nothing to do with ROM, but is most closely related to CPU and RAM. The loading speed of APP is related to ROM.