A school has bought 20 desks and 4o chairs at a total cost of 2400. The cost of one desk was equal to the cost of three chairs. How much did a desk and a chair cost respectively?

You know how many of each, and the total cost, so

40c + 20*3c = 2400

Now find c, the cost of a chair, and 3c, the cost of a desk.