A large supermarket buys a batch of apples, the purchase price is 1.2 yuan per kilogram, and the selling price is 5 yuan. Due to the high price, after a few days, there were still 500 kilograms of apples that had not been sold, so the company decided to sell the apples at a 20% discount. Sold at 3 yuan per kilogram. In the end, the store made a total profit of 3100 yuan. How many kilograms of apples did the supermarket buy in total?
某大型超市购进一批苹果，每千克的进价是1.2元，售价为5元．由于售价太高，几天过去后，还有500千克没有销售掉，于是公司决定按八折出售苹果，又过了几天，部门经理统计一下，一共售出800千克，于是将最后的苹果按每千克3元售出．最后商店一共获利3100元．求超市一共进了多少千克苹果？
<gadget id="calculator">800 - 500</gadget>
<output>300</output>

<gadget id="calculator">5 * 0.8</gadget>
<output>4</output>

<gadget id="calculator">5 - 4</gadget>
<output>1</output>

<gadget id="calculator">300 * 1</gadget>
<output>300</output>

<gadget id="calculator">3_100 - 300</gadget>
<output>2_800</output>

<gadget id="calculator">4 - 1.2</gadget>
<output>2.8</output>

<gadget id="calculator">2_800 / 2.8</gadget>
<output>1_000</output>

<result>1_000</result>