Sanjay's investment for 1 months = 15000 x 12 = Rs. 180000
Komal's investment for 1 months = 15000 x 8 + (15000 - 10000) x 4
= 120000 + 20000
= Rs. 140000
∴ Ratio between the investment of Sanjay and Komal
= 180000 : 140000 = 9 : 7
∴ Sanjay's profit = [9/(9 + 7)] x 32000 = Rs. 18000