The law isn't justice. It's a very imperfect mechanism. If you press exactly the right buttons and are also lucky, justice may show up in the answer.
I am always glad to think that my education was, for the most part, informal, and had its roots in the soil.