Now on this entry we'll talk about Programming Logic and it's advantages. It's funny how the lecture introduce it as a Harry Potter chapter, because is closest to real magic in the programming world. But, what is programming logic? It describes the constraints and relations of the problem, without telling how to do the whole problem.
To do this, first of all we need to get know about how miniKanren works and their utilities. miniKanren is a language to run backwards your program, what it makes it more interesting to get know how it works, with the help of core.logic
In my opinion I think even if this is more direct, I mean as telling the program what you want and it's restrictions making the code shorter have a price at the moment of debugging.
The lecture also teach us how to use these tools and it's important that core.logic is an embedded miniKanren that is useful to combine the best of Clojure and logic programming. I like the way the lecture explain this concept, because there are many analogies that can make us understand how programmig logic works. It's not easy, because we are used to code each step well detailed, to get what we want, I see as an algorithm that is serie of steps that tells the program which way to follow. Now logic programming allow us to code in reverse, making the code shorter, with the help pf core.logic this is possible, also exists core.match.
In conclusion, I see that there are equivalences with other commands like conda or fresh, but it's important to understand that logic programming does not return false or true, instead of that is a success or a fail, but with the time I hope getting used to this new language, even is better on some problems, the restrictions and the entries it's what makes everything.