Law is a set of rules created and enforced by social or governmental institutions to regulate behaviour. Its precise definition is a matter of longstanding debate. It has been variously described as a science and as the art of justice. Law shapes politics, economics, history and society in many ways, serving as a mediator of relations between people. A broad distinction can be made between (a) civil law jurisdictions, where a legislature or central body codifies and consolidates its laws; and (b) common law systems, where judges make precedent. There is also a difference between legal systems that are religious and those that are secular, with religious law still having a significant impact on the settlement of disputes in some parts of the world.
The purpose of law is to keep society orderly, and to punish criminals and to protect citizens. In addition, it serves to prevent racial or ethnic conflict, maintain public health and safety, regulate commerce, ensure a safe environment, and settle property disputes. In the context of international affairs, it is important to promote peace and stability through the rule of law.
While the exact nature of law is subject to ongoing discussion and dispute, there are a number of core features that it must possess in order to be considered to be such. First, it must be objective, and not subjectively based on individual biases or prejudices. Second, it must be clear and accessible to the citizenry, and easy to understand. Third, it must have some degree of consistency and predictability. Fourth, it must be general, not confined to particular orders or societies. Finally, it must be enforceable, meaning that there must be means by which to determine whether a given statement is in fact lawful or not.
In this context, the law is a collection of precepts that are designed to be applied consistently and fairly by people in their day-to-day activities. It reflects the values and attitudes of those who make it up, but it is not itself a theory of morality, good or evil, empirical or social science or any other complex metaphysical or intellectual construct. Moreover, while law can be used for very bad purposes it does not imply that the laws themselves are intrinsically good or morally righteous.
As such, the laws we live by are often a mixture of both practicality and philosophy. They are shaped by the need to balance the interests of different groups and to make compromises. The most basic laws are those that ensure a high standard of living and the protection of personal freedoms. This is why there are laws against murder, theft and fraud. However, laws may also impose restrictions on behaviour that are intended to promote public safety, such as wearing seatbelts, not smoking in public or playing music loudly late at night. There is even a law against aggressive telemarketing. Similarly, a government might introduce a law against tax breaks for big business that is not benefiting the country as a whole.