Answer
The code is:
042
Explanations:
One number is correct and is also correctly placed:
2
One number is correct but wrongly placed:
4
Two numbers are correct and wrongly placed:
0 & 2 incorrectly placed
Nothing is correct:
None of them are in the code
One number is correct but wrongly placed:
0
Approach/Thought Process Chosen
682 - One number is correct and well placed
Correct Number's array - 6,8,2
Confirm Number's array -
614 - One number is correct but wrong placed
Correct Number's array - 8,2,1,4(6 is removed since this clue contradicts the previous one and hence 6 should not be present even in the code-The position of 6 is same in Clue 1 and 2 which mean's it can be pushed out of scope)
Confirm Number's array -
206 - Two Numbers are correct but wrong placed
Correct Number's array - 8,2,1,4,0
Confirm Number's array - 0_2(Since 6 is out of scope, consider 2 and 0 to be in the confirm array list and clue 1 says 2 is well placed )
738 - Nothing is correct
Correct Number's array - 0,2,1,4(8 is removed from the array)
Confirm Number's array - 0_2
780 - One Number is correct but wrong placed
Correct Number's array - 0,2,4(Clues 3 and 5 confirms the position of 0 to be the first. Clues 1 confirms the position of 2. Clue 2 confirms the position of 4 and hence 1 is removed from the list)
Confirm Number's array - 042
No comments:
Post a Comment