Did M1 's prequel 's executive producer write M0 's sequel
SELECT count(*) WHERE {
?x0 ns:film.producer.films_executive_produced ?x1 .
?x0 ns:film.writer.film ?x2 .
?x1 ns:film.film.sequel M1 .
?x2 ns:film.film.prequel M0
}