(1) Primary Memory Primary Memory holds only those data and instruction on which the computer only working. It has a limited capacity and data is lost when the power is switched off. It is generally made up of semiconductor device. It is divided into two subcategories RAM and ROM. Primary Memory is faster than Secondary Memory.
(2) Secondary memory This type of memory is also known as external memory or non volatile memory. It is slower than the main memory. this is used for storing data/information permanently. CPU does not accessed memories instead they accessed input output routines. These are optical and magnetic memories. It is known as backup memories. It is used for storage of data in a computer.