Let the amount of money lent at 12% interest be ₹ P.
∴ Amount of money lent at 12.5% interest = ₹ (2540 - P)
According to the question;
(P x 12 x 1)/100 + [(2540 - P) x 12.5 x 1]/100 = 311.60
⇒ -0.5P/100 + 31750/100 = 311.60
⇒ 0.5P = 31750 - 31160 = 590
∴ P = ₹ 1180