Did M2 write and direct a film that was written by and was produced by a film director
SELECT count(*) WHERE {
?x0 a ns:film.film .
?x0 ns:film.film.produced_by|ns:film.film.production_companies ?x1 .
?x0 ns:film.film.written_by ?x1 .
?x1 a ns:film.director .
M2 ns:film.director.film ?x0 .
M2 ns:film.writer.film ?x0
}