Submit | All submissions | Best solutions | Back to list |
Problem hidden on 2014-03-16 20:11:03 by Francky
PD - Password Dilemma |
Jim is in a fix. He needs a password to time travel. The password consists of only numbers. The password has to be entered only in a particular pattern on a keypad and the size of the keypad keeps changing every time he time travels. Jim doesn’t want to type the password every time he wants to time travel. Jim has come to the future looking for someone who can help him in automating the password entry. Help Jim in doing so.
Input
The first line is a number N (the size of the keypad) based on which the password has to be generated. (1<=N<=10).
Output
Output the password based on N. Each number should be separated by one tab space.
Test Cases
Input 1:
4
Input 2:
2
Output 1:
1 2 3 4
12 13 14 5
11 16 15 6
10 9 8 7
Output 2:
1 2
4 3
Added by: | Arjun Krishnan |
Date: | 2014-03-16 |
Time limit: | 3s |
Source limit: | 50000B |
Memory limit: | 1536MB |
Cluster: | Cube (Intel G860) |
Languages: | ASM32-GCC MAWK BC C-CLANG C NCSHARP CSHARP C++ 4.3.2 CPP CPP14 CPP14-CLANG COBOL COFFEE D-CLANG D-DMD DART ELIXIR FANTOM FORTH GOSU GRV JS-MONKEY JULIA KTLN NIM OBJC OBJC-CLANG OCT PHP PICO PROLOG PYTHON PYPY PYPY3 R RACKET RUST CHICKEN SQLITE SWIFT UNLAMBDA VB.NET |
hide comments
2014-03-17 13:27:57 Francky
Language restriction unjustified : hidden until change done (Please allow all language). Obviously moved to tutorial, or riddle if many people ask for, but I doubt. |
|
2014-03-17 13:27:57 Jacob Plachta
Yeah, this should be in Tutorial. |
|
2014-03-17 13:27:57 Pranay
Though tutorial stuff, why language restrictions ? |
|
2014-03-20 12:01:25 785227
@ Aravindan , Yes u r right |
|
2014-03-20 12:01:31 Aravindan Chandrasekaran
2nd row 3rd column ... it has to be 14 right ? Its 14 guys ... Not 4 Last edit: 2014-03-16 11:20:01 |