ISLAMABAD — The prime ministers of nuclear-armed rivals Pakistan and India agreed at a rare meeting on Friday to cooperate on eliminating terrorism in South Asia, Pakistan's Foreign Ministry said. In a sign of easing relations, Indian Prime Minister Narendra Modi also accepted his Pakistani counterpart Nawaz Sharif's invitation to attend a South Asian regional summit to be held in Islamabad next year. “Both sides condemned terrorism in all its forms and agreed to cooperate with each other to eliminate the menace of terrorism from South Asia,” Pakistani Foreign Secretary Aizaz Ahmad Chaudhry said in a statement. Sharif and Modi met in the Russian city of Ufa, where they are attending summits of the BRICS trade group and the Shanghai Cooperation Organization. Pakistani television showed the pair shaking hands and smiling. The hostility between Pakistan and India dates back seven decades, but strains have grown since nationalist Indian Prime Minister Narendra Modi took office a year ago. — AP