The republics of India and Pakistan were created in 1947 when the British Raj pulled out of the subcontinent.