Plot[Which[x<=4,2x-4,
	       x<=10,6-x/2,
	       x<=12,1],{x,0,12},
	       AxesLabel->{"x","y"},
	       PlotRange->{{0,12},{-4,4}},
	       AxesOrigin->{-0.25,-4.25},
	       PlotLabel->"Figure 9.7\n\n\n  y = g(x)",
	       GridLines->Automatic]