This concept is based on the law of one price which tells the same good will cost the same in different countries if the transaction cost and trade barriers are removed. It is calculated as
Purchasing Power Parity = P1/P2
P1 = Price in currency 1
P2 = Price in currency 2
1 burger costs $1 in America. One burger in India costs Rs. 52.
Purchasing Power Parity = 52/1=52
1 haircut might cost 10$ in US but might cost 30 Rs in india. But as per the exchange rates 10$ approximately is equal to 500 Rs in India. So in the same amount of Money, You can buy more things in India as when compared to US. so in this case
PPP is 30/10=3 and exchange rates stand at 50/1 = 50.