The shares of Ravi and Rani in the profit will be in the ratio of their invested money ratio.
So ₹40,000 is to be divided in 5:3 among Ravi and Rani
Sum of the ratio parts = 5+3 = 8
5 parts of the ratio = ₹40,000
1 part of the ratio = ₹40,000/8
= ₹5,000
Ravi’s share in profit = 5 x ₹5,000 = ₹25,000
Rani’s share in profit = 3 x ₹5,000 = ₹15,000