A retailer allowed 12% discount and sold a T-shirt at a loss of Rs 16. If he had sold it at 10% discount he would have gained Rs 20. For what price did he purchase the T-shirt?​