Did a film director that M0 was directed by and was written by play M1 and M2
SELECT count(*) WHERE {
?x0 ns:film.actor.film/ns:film.performance.character M1 .
?x0 ns:film.actor.film/ns:film.performance.character M2 .
?x0 ns:film.director.film M0 .
?x0 ns:film.writer.film M0
}