Anuj had some chocolates, and he divided them into two lots A and B. He sold the first lot at the rate of ₹2 for 3 chocolates and the second lot at the rate of ₹1 per chocolate, and got a total of ₹400. If he had sold the first lot at the rate of ₹1 per chocolate, and the second lot at the rate of ₹4 for 5 chocolates, his total collection would have been ₹460. Find the total number of chocolates he had.