The order is important!
(a) & (b) have different meanings:
(a): For all M in R, there exists n in N such that …
(b): There exists n in N such that for all M in R, …
See also example below:
Ref: “The Math Girls”