A chemist prepares 100 grams of medicine by mixing two ingredients X and Y. The rate of X is ₹1,500 per 100 grams and that of Y is ₹50 per 10 grams. X and Y are mixed in such a way that the cost of the resulting medicine is ₹13 per gram. What is the quantity of X (in grams) in the medicine ?