All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars    
perplexus dot info

Home > Logic
Keycode (Posted on 2007-09-06) Difficulty: 2 of 5
Every day when Frank goes to work, he needs to enter a keycode with six different digits to get into the building. The front door has one keypad style and the back door has a different keypad style. One day, Frank realized that each digit in his keycode was horizontally, vertically or diagonally adjacent to the next digit on both keypads.

If the first digit of Frank's keycode is larger than the last, can you determine his keycode?

    Front               Back
+---+---+---+   +---+---+---+---+---+
| 1 | 2 | 3 |   | 1 | 2 | 3 | 4 | 5 |
+---+---+---+   +---+---+---+---+---+
| 4 | 5 | 6 |   | 6 | 7 | 8 | 9 | 0 |
+---+---+---+   +---+---+---+---+---+
| 7 | 8 | 9 |
+---+---+---+
    | 0 |
    +---+
Example: 2,6 is a possible part of the keycode but 3,6 and 1,6 are not since those are adjacent on only one keypad.

See The Solution Submitted by Brian Smith    
Rating: 3.6250 (8 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
Solution Full Solution with explanation | Comment 11 of 14 |

Looking at the keypads the only possible pairing of digits to satisfy both are:

0-9
1-2
2-3
2-6
4-5
4-8
5-9
7-8
8-9

the digits 1, 3 and 6 only appear once so therefore can only appear either at the end or the beginning of the code. However all these three digits only pair with 2, and 2 pairs with no other so it isn't possibly to use these in a 6-digit code (can only produce a 3 digit code). This leaves the pairs of:

0-9
4-5
4-8
5-9
7-8
8-9

The 6 different digits are therefore 0, 4, 5, 7, 8 and 9.

0 only appears once so must be at the beginning or end. The first digit is larger than the last digit so 0 must be at the end and so 9 must be the 2nd to last digit.

A-B-C-D-9-0

There is only one 7 so this must be the first digit and 8 must therefore be the 2nd digit.

7-8-C-D-9-0

8 can be paired with 7, 9 and 4.
7 and 9 have already been used in the code so the 3rd digit is 4 and therefore the 4th digit is 5.

7-8-4-5-9-0

Nice puzzle Brian!


  Posted by Lisa on 2007-09-11 05:51:42
Please log in:
Login:
Password:
Remember me:
Sign up! | Forgot password


Search:
Search body:
Forums (1)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (6)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Chatterbox:
Copyright © 2002 - 2024 by Animus Pactum Consulting. All rights reserved. Privacy Information