This is classic logic game:
The game computer thinks of a number (set) of the four non recurring digits. The player has got several attempts to guess the unknown number. Each attempt player gets a clue: how many digits in the number, he guessed, and how many of them are located in the right place.
Example: Computer unknown number of characters is 1234.
The player has entered a try: 3784. As a result, the player will receive a prompts:
"there are 2 characters in the set",
and "one sign on the right place".
The game continues until the player guesses the unknown number, or do not use up attempt.