To answer this question, we need to use our knowledge of both slope/intercept, and of inequalities.
First, when graphing an inequality, if the inequality is greater than or equal to (or less than or equal to), a solid line is used. When the inequality is strictly less than or greater than, a dotted line is used.
Next, using our knowledge of slope/intercept, we can see where the lines are to cross the y-axis, and which direction they are supposed to travel.
For the first, the line will cross the y-axis at (0,-2), and rises. Because this is less than/equal to, a solid line is drawn. For the second, the line will cross the y axis at (0,4), and falls. Because this is strictly greater than, a dotted line is drawn.
Now to determine the solutions: shade the regions that satisfy each. For the first, because it is less than/equal to, you shade BELOW the line. For the second, because it is greater than, you shade ABOVE the line. The area where the two shaded regions intersect is the solution set. Thus, the solution is D.