Like attention, no more lost, your support means a lot to me!
🔥 Hi, I’m Chouchou. GitHub · Android-Notebook has been included in this article. Welcome to grow up with Chouchou Peng. (Contact information at GitHub)
preface
- In computer interviews, logic questions are a must for large Internet companies. Due to the variety of the topic, the preparation is difficult, the sea of tactics may not be recommended.
- In this article, I will select ten very classic logic problems that I hope will help you find some ideas/techniques for solving them. Please be sure to like and follow if you can help, it really means a lot to me.
series
- The logic | “I know you don’t know!” “
- The logic | DE maisie, arc weight!”
- “The logic | dark please close your eyes!”
- The logical | racing!
[Continuous update]
1. “I know you don’t know”
1.1 Description
A and B asked C’s age curiously, C gave the following 11 numbers, C’s age is one of them:
35, 36, 38,
42, 45, 46,
51, 55, 57,
61, 62,
.
Cryptic C tells A the tens digit and B the ones digit. At this point, A and B have the following conversation:
A: I don’t know C’s age, and I know you don’t.
B: I didn’t know, but now I know.
A: Now I know, too.
May I ask C’s age?
1.2 Key to solving the problem
- 1. “I know you don’t know” means
Based on the information I have available, I know that you have not obtained sufficient conditions for the proposition. More colloquially, I don’t know what you’re in, but you’re definitely not in a state where you can infer results.
- 2. “uniqueness” implies sufficient conditions
There are three numbers, 36, 46 and 57, and given that the units digit of the target number is 7, it is obvious that the number is 57 (because only one number has the units digit 7).
1.3 answer key
Now, let’s elaborate on the process of solving this problem:
- First we observe 11 numbers :(35, 36, 38, 42, 45, 46, 51, 55, 57, 61, 62)
There are three, four, five, six possible tens, all of which match more than one digit.
The units digit can be 1, 2, 5, 6, 7, and 8. 1, 2, 5, and 6 match multiple digits, while 7 and 8 match 57 and 38 respectively.
- A: I don’t know C’s age, and I know you don’t.
First of all, A says “I don’t know C’s age”, indicating that tens are not unique. Since ten digits 3, 4, 5 and 6 all correspond to multiple numbers, no number can be excluded at present.
A: I know you don’t know. In other words, I know you don’t have A sufficient condition for the proposition. In other words, I know you don’t have A 7 or an 8.
Why would A dare to assert: “You must not have 7 and 8”? It must be when A has ten digits and it’s not A three, it’s not A five. Only in this way can we make sure that the age is not 3_ or 5_, so it cannot be 57 or 38.
- At this point, observe the following numbers remaining :(42, 45, 46, 61, 62)
The units digit can be 1, 2, 5, or 6. 2 matches multiple digits, while 1, 5, and 6 match 61, 45, and 46, respectively.
- B: I didn’t know, but now I know.
And then B says, “I know,” which means that if we have a unique sufficient condition, then the units digit of age must not be 2.
- At this point, observe the following numbers remaining :(61, 45, 46)
There are two possible tens: 4 and 6, where 4 will match more than one number, and 6 will match 61.
- A: Now I know, too.
At this point, A says, “I know, too,” which means that the unique sufficient condition is met, so the age is 61.
The theory of bi.
Creation is not easy, your “three lian” is chouchou’s biggest motivation, we will see you next time!