Were M3 and M4 directed by and written by a American actor of 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:people.person.nationality ns:m.09c7w0 .
M3 ns:film.film.directed_by ?x0 .
M3 ns:film.film.written_by ?x0 .
M4 ns:film.film.directed_by ?x0 .
M4 ns:film.film.written_by ?x0
}