Calculating Consumer Surplus Given Table
The key to this is in the hint. It lets you know supply and demand are both linear, so you need to figure out what the functions of those two curves are. In this case, you have
$$ Q_D = 18 - 1.5P $$
$$ Q_S = 3P $$
Plot these on a supply/demand graph (P on the vertical axis, Q on the horizontal), and the consumer surplus is the shaded area (note, it stops at Q=6 because only 6 units were traded in the question):

Using the formula for the area of a trapezoid, we have:
$$ CS = \frac{1}{2} [(12-4)+(8-4)]*6 = 36 $$