In a computer there is a component which in called R.A.M (random access memory) it is pretty much where all your currently running programmes on your computer are stored. The R.A.M is also volatile so this means that it loses all of the data stored inside the R.A.M when it is turned off. Anyway back onto what virtual memory is, the R.A.M only has a certain amount of storage inside of it which is usually quite small and say if you had a lot of programmes running at the same time then it would fill up that storage inside of the R.A.M. So this is when virtual memory comes into play, once all the storage inside the R.A.M is full up the programmes have no where to go so they use the memory on the hard drive since it has loads of storage. Then least frequently used programme or (page) will be stored on the hard drive as a thing called virtual memory.
I hope you have enjoyed this post and have learned something new today.
Make sure to follow and upvote i would really appreciate it thanks <3