Anyone who wants to seriously approach the study of Artificial Intelligence starts by studying the Constraints Satisfaction Problem. In this article, I will introduce you to CSPs: I will explain what they are, how they can be useful to you, and how to solve them, through a practical example derived directly from the kangaroo nation 🦘.
Nowadays, CSPs are used in many fields, such as biology (DNA sequencing), Constraint Databases, Diagnosis, Natural Language Recognition, and so on.
Constraint Satisfaction Problems (CSP) represents a class of problems where there are some restrictions between objects within that problem.
In a formal way…
The Command Design Pattern is a behavioural design pattern, and as such is responsible for making two actors communicate in an efficient and maintainable way.
Often, an object (the Sender) makes a request to another object (the Receiver). Doing this in a naive way requires the Sender to know who the Receiver is at compilation time; if the Receiver changes, you will also have to change the Sender’s code, replacing the old Receiver with the new Receiver.
To avoid this, the Sender’s request is encapsulated in a separate object: the Command.
In addition, by transforming the requests into objects, there…
🇪🇺 European Android Developer