Update (2013): I no longer squish dying worms because I fear doing so may cause more harm than if they died on their own. I do, however, try to move them off the pavement onto the grass so that other pedestrians won't inadvertently half-crush them.
It rained last night, and this morning, I was not surprised to see a number of earthworms strewn across a stone walking path. While a few of the worms appeared healthy enough to return safely to the soil, most were clearly either dead or sufficiently incapacitated that they would die within a few hours.
The sight is truly painful. When I'm not in a hurry, I feel obligated to stop and completely squish those worms that appear to be suffering but not yet dead. I make sure to slide my foot along the pavement so that the guts of the worm are stretched out, ensuring a quick and certain death. This is, I think, what I would most want someone to do to me if I were going to be transformed into a worm in such a situation. (It's the opposite approach, I assume, from what a Buddhist or Jain would do, which seems to me unfortunate given their supposed concern for all creatures. Sometimes reverence for life ends up causing more suffering.)
The task of squishing worms feels overwhelming, because there is a practically unlimited supply of nearby places I could go where I could find dying worms on pavement. It would probably not be optimal for me to spend my life seeking out worms so that I could put them out of their misery. But this is not because the expected reduction in suffering due to stepping on worms is small: Indeed, if we give worms, say, a 1/3 chance of being able to feel pain, and if only 1/3 of the worms I step on are not yet dead or unconscious, then in the five minutes it takes me to step on 25 of them, I will have averted roughly three expected experiences of slow, lingering death. Rather, the reason it probably is not cost-effective to spend my life on this task is that the stakes in other domains are so much higher: The amounts of suffering in nature as a whole are vastly higher, "beyond all decent contemplation."
In theory, it would be optimal for me to bypass the worms on the sidewalk so that I could have an extra few minutes to do more abstract work that has far higher expected returns. The reason I don't do so, apart from feelings of direct pity, is somewhat selfish: Thinking about how much I ought to be getting done in the five minutes I save is stressful and overwhelming. It's hard to go through life with the mindset that every five minutes you waste on trivialities amounts to (far) more than three expected worms suffering while they die helplessly. And yet this is true. The best excuse I can give is that humans are not built to handle emotional burdens on this scale.
By the way, if readers have suggestions on the worms-in-the-rain situation, I would be glad to hear them. As far as I can tell, the worms come out to escape drowning, though they may also use the moisture as a chance to mate. In either case, though, it's clear that many of the worms on the pavement are in no position to return back to the soil, as is demonstrated by their shriveled-up remains the following day. It's not obvious that the rain or pavement themselves are to blame, because, as Charles Darwin suggested, it may be that many of these worms "were already sick, and that their deaths were merely hastened by the ground being flooded." If that is the case, then worms in the rain represent merely a glimpse of the vast amounts of sickness and death that occur all the time among animals in the wild.
Note: Professor Jeffrey Lockwood wrote a nice reply to this blog post, which appears as the third comment below.