What is context switching ?

In a simple term context switching means Adjusting memory in RAM.

Whenever a program is getting executed stack will store the variables. At the same time one more memory will store the function call history. That memory is less so when that does not have memory to allocate then the last uncalled function will be removed and it is saved to the new memory called Paging Memory. In case of linux paging memory is called as swapping. This is called context switching.