Computer Memory is mainly divided into two parts, one of them is known as primary or main memory and the other one is known as secondary memory.
Primary Memory: is a part of main computer system. All the information that CPU use to store and get is through the primary memory. This mean that all the information stored in primary memory is easily accessible through CPU. Primary memory itself is classified into two categories.
These two categories are RAM (random access memory) and ROM (read only memory). As the name of these two memories telling us the RAM is a type of memory which is readable and writeable. CPU can read and write the information from primary storage area through RAM. RAM is further classified as DRAM (Dynamic random access memory), RDRAM (Rambus DRAM), SDRAM (Synchronous DRAM), DDR SDRAM (Double Data Rate SDRAM), DDR2 SDRAM(Double Data Rate SDRAM) etc. The other part of primary storage is just readable. No changes can be brought in that part of primary memory through CPU. Primary memory is much faster in speed and with that it is cost effective.
The other type of computer memory is called secondary memory.
Secondary Memory: is slowest and the cheapest form of memory. CPU cannot process this memory directly, to do any processing on this memory firstly it has to be copied into the primary memory. It use to store data permanently but as long as it is not being erased from the memory. Secondary memory is mostly available in the form of floppy disk, hard disk, CD, DVD, pen drives and memory cards etc. A 5 and ¼ inches floppy dish can store upto 1.44MB of data. On floppy disk data use to be stored in organization of tracks and sectors. Hard disk or hard drive can store large capacity of data. Its range is from 80 to 300 GB or even higher. Hard drive is actually made of many platters, and all the data use to be stored on these platters. This is much faster then floppy disk and with that it can store much larger quantity of data. A CD (Compact Disk) can store upto 750MB of data. On CD as well data use to be stored in pattern of tracks. DVD( Digital Versatile Disk) can store about 4.6 GB of data and information. All these drives are read and writeable. Which mean that the data stored on it can de removed anytime and new data can be added very easily.
Beside these two types of memory there are some other types as well.
Virtual Memory: this memory is used when amount or data that has to be stored is much larger than the capacity of RAM. Operating system use to store that excessive data on hard drive temporarily and use to take it back from their when need is over. The working in this type of memory is much slower than actual RAM and use to degrade the performance of working.
Cache Memory: this is used between CPU and RAM, so that most frequently used data or instructions can be handled and executed. Cache memory is further divided into 3 levels. Level 1 is primary and is close to processer. It use most frequently used data. Level 2 is close to CPU and motherboard. Level 3 is most advanced and speedy. This also uses to help in execution of frequently used data.
Volatile Memory: is a computer memory that need power to main the storage of information in it. Dynamic RAM is a kind of volatile memory because it works as long as CPU is connected with electric power. Because Dynamic RAM need regular refresh cycles to prevent loss of data. Moment when the power turned off, all the data stored in this erase automatically.
Non Volatile Memory: is type of memory which retains the information even loss of electric supply. ROM, flash memory, hard disk, magnetic tapes etc comes under this type of memory.