Were M3 and M5 written by M4 and written by a Mexican star of M1 and M2
SELECT count(*) WHERE {
?x0 ns:film.actor.film/ns:film.performance.film M1 .
?x0 ns:film.actor.film/ns:film.performance.film M2 .
?x0 ns:people.person.nationality ns:m.0b90_r .
M3 ns:film.film.written_by ?x0 .
M3 ns:film.film.written_by M4 .
M5 ns:film.film.written_by ?x0 .
M5 ns:film.film.written_by M4
}