They did so to protest society's double standard when it comes to the acceptability of men appearing in public shirtless versus the unacceptability of women failing to cover their "upper torsos" in public (link below). They actually weren't doing anything illegal since, reportedly, "Maine's nudity laws only apply to exposed genitals."
But here's the thing that I don't get: Apparently many of the topless marchers were "surprised" and "upset" that a number of men showed up for this event and took pictures. Are you kidding me? The only "surprise" would have been if men didn't show up to take pictures. Now that would have had me wondering. Just look at the faces of some of these dudes -- they really did seem to be enjoying themselves. And as for being "upset," I say that if you choose to walk down a public street topless and are anticipating that only stone-faced men will be there sporting no cameras, then you might just need to have examined that thing that appears immediately above your "upper torso." Just a thought.