Why do we have laws, and what is the purpose of laws?

Updates
5 mo
I guess I wasn't clear enough here. Let me expand the question just slightly. What is the purpose in writing a law? What is the purpose in invoking a law and enforcing it? What is the end goal of doing these things?
Updates
5 mo
My purpose in writing this question was not to provoke or even entertain a political discussion, but rather to explore your thinking regarding the origins, meaning, and purpose of laws, of making laws and enforcing laws, and how they serve or harm all of us. I find that I have many questions about these things myself, so your input and discussion with me are very welcome. I would ask you to refrain from political commentary, if possible, at least on this question.
Why do we have laws, and what is the purpose of laws?
Post Opinion