Oh goodness. Levi goes to the groomer every 8 weeks, and he can still look like a sweet little disaster if we are headed home from a walk or the park or somewhere he has been playing hard. I know he's come back from the dog park many times with muddy paws and tangled hair - but happy, healthy, and cared for. He doesn't always get a bath or a brushing before making a public appearance, so I am sure sometimes my crazy wild man looks a bit messy.
But if this stranger's pup really looked neglected, I'd find some to bring it up gently. I think the question of "what groomer do you use" is a good idea. It's not a confrontational question, but it gets to the point.