Write SQL query to solve given problem: Which courses were taught by a professor who is not a faculty member?. Keep the solution inside sql tag ```sql [SQL-Query] ```
SELECT DISTINCT T2.course_id FROM person AS T1 INNER JOIN taughtBy AS T2 ON T1.p_id = T2.p_id WHERE T1.professor = 1 AND T1.hasPosition = 0