Since you can select names of professors who teach course of year 2, I assume you already know how to SQL JOIN.
If I understand you correctly, you want names of those professors who ONLY teach year 2, that is to exclude any one who teaches other years even if he also teaches year 2. The pseudo sql code is like this:
SELECT professor_name
FROM multiple table join
WHERE NOT EXISTS(
SELECT professor_name FROM multiple table join
WHERE year = 1 and year = 3...
) AND year = 2
You may use NOT IN. Google for some reference online.