Was M0 a female person that M2 was written by and M3 starred
SELECT count(*) WHERE {
M0 a ns:people.person .
M0 ns:film.actor.film/ns:film.performance.film M3 .
M0 ns:film.writer.film M2 .
M0 ns:people.person.gender ns:m.02zsn
}