Catherine had an equal number of pencils and pens. If she had 60 pens and gave eight pens and 6 pencils to each of her seven friends and kept the rest for herself, how many pens and pencils did she have left?
Catherine gave eight pens to each of her seven friends, a total of 8*7 = 
<gadget id="calculator">8*7</gadget>
<output>56</output>
56 pens.
She remained with 60-56 = 
<gadget id="calculator">60-56</gadget>
<output>4</output>
4 pens.
When she also gave 6 pencils to each of her seven friends, she gave away 6*7 = 
<gadget id="calculator">6*7</gadget>
<output>42</output>
42 pencils.
Since she had the same number of pencils as pens, she remained with 60-42 = 
<gadget id="calculator">60-42</gadget>
<output>18</output>
18 pencils.
The total number of pens and pencils that Catherine remained with is 4+18 = 
<gadget id="calculator">4+18</gadget>
<output>22</output>
22.

<result>22</result>