This website works better with JavaScript.
Home
Help
Sign In
sm
/
mebipenny
Watch
1
Star
0
Fork
0
Code
Issues
0
Pull Requests
0
Activity
Browse Source
call me maby solution
master
Stephen McQuay
8 years ago
commit
cf17dc32c9
2 changed files
with
30 additions
and
0 deletions
Split View
Diff Options
Show Stats
Download Patch File
Download Diff File
+27
-0
call-me-maybe/call_me_maybe.py
+3
-0
call-me-maybe/stdin1.txt
+ 27
- 0
call-me-maybe/call_me_maybe.py
View File
@ -0,0 +1,27 @@
import
sys
mebi_mapping
=
{
0
:
'
0
'
,
1
:
'
1
'
,
2
:
'
ABC
'
,
3
:
'
DEF
'
,
4
:
'
GHI
'
,
5
:
'
JKL
'
,
6
:
'
MNO
'
,
7
:
'
PQRS
'
,
8
:
'
TUV
'
,
9
:
'
WXYZ
'
,
}
lookup
=
{
}
for
k
,
v
in
mebi_mapping
.
iteritems
(
)
:
for
c
in
v
:
lookup
[
c
.
lower
(
)
]
=
str
(
k
)
lookup
[
str
(
k
)
]
=
str
(
k
)
for
line
in
sys
.
stdin
:
number
=
'
'
for
c
in
line
.
strip
(
)
:
number
+
=
lookup
[
c
.
lower
(
)
]
print
number
+ 3
- 0
call-me-maybe/stdin1.txt
View File
@ -0,0 +1,3 @@
5551234
GOPANDA
MebiPenny2012
Write
Preview
Loading…
Cancel
Save