There are three kinds of goods A, B, and C. If you buy 3 pieces of A, 7 pieces of B, and 1 piece of C, the total cost is 20 yuan; if you buy 4 pieces of A, 10 pieces of B, and 1 piece of C, the total cost is 27 yuan; then buy A, B, and C each have 1 piece, how much is the total cost?
有甲、乙、丙三种货物，若购甲3件、乙7件、丙1件，共需20元；若购甲4件、乙10件、丙1件，共需27元；则购买甲、乙、丙各1件，共需要多少元．
<gadget id="calculator">20 * 2</gadget>
<output>40</output>

<gadget id="calculator">27 - 20</gadget>
<output>7</output>

<gadget id="calculator">40 - 27 - 7</gadget>
<output>6</output>

<result>6</result>