The salary hike is calculated by finding the difference between the new salary and the current salary. Then it divides the difference by the current salary and then multiply by 100 to get the percentage increase.