So for A, the answer is 3. Slopes of parallel lines must be the same, and in the equation in A, the slope is 3, so therefore the slope of any parallel line must also be 3.
For B, to find a perpendicular slope, you must do the negative reciprocal of the slope. So in the example they give, -2 is the slope. So to find a perpendicular line, do the negative reciprocal of -2, which is positive 1/2 (one half).