in reply to Re: Confusion in working upon regex with /m
in thread Confusion in working upon regex with /m

That will never match. $ has to be followed by a line feed or EOS, and you also require that it's followed by a y. Those are mutually exclusive requirements.