Steve started with 2 * 12 = <<2*12=24>>24 pencils.
He gave Matt 6 + 3 = <<6+3=9>>9 pencils.
After giving away the pencils, Steve will have 24 – 9 – 6 = <<24-9-6=9>>9 pencils left.
#### 9