In school I once read a story that I've now mostly forgotten. There is only one part that I remember.
A wealthy man is frustrated that the poor farmers that farm his land steal his firewood. His solution was to drill holes in the wood that he knew would be stolen. He filled the holes with gun powder and covered them with wax. the offender would get a surprise when the burnt the ill gotten wood.
For some reason I championed the cruel landlord. It appealed to some sense of rigid justice.
The story I just posted was formed around the notion of creating one's own justice by playing by the rules of those who break the established rules of the land. I thought I liked that idea.
When I got done with the story and read it I was shocked. The man that I thought was the hero was actually an uncaring monster. I didn't like him at all. I also began to see the "villains" as victims of circumstance and society. I began to feel like they had been the recipients of injustice, not only by society but ultimately by a man who could only see from a narrow and selfish perspective.
For me writing the story was interesting in how my perspective changed as a result.
I'm not saying that there are really any clear cut good or bad guys in my story. There is a lot of gray. I guess that our reactions to the story tell more about us than it does the characters--characters that are made up after all.
Writing is great because it helps us to see and understand.