follow(S) = first(P)
first(P) = {p, ϵ}
follow(S) = {p, $} since first(P) contains ϵ so, follow(S) will also contain first(Q).
So, first(Q) = {q, ϵ}
follow(Q) = (p, q, $) and first(Q) contains ϵ so, follow(S) will also contain first(R).
first(R) = {q, r, m, ϵ}
follow(S) = {p, q, r, m, $}.
S is start symbol so $ will also be in follow(S)
So, the correct answer is A.