Our server costs ~$56 per month to run. Please consider donating or becoming a Patron to help keep the site running. Help us gain new members by following us on Twitter and liking our page on Facebook!
Current time: February 17, 2025, 1:12 am

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Bruteforce
#4
RE: Bruteforce
Found this, if you change the 'digit map' it will do what you want apparently. (I'm not familiar with 'Python', BTW)

digit_map = {
'2': 'abc',
'3': 'def',
'4': 'ghi',
'5': 'jkl',
'6': 'mno',
'7': 'pqrs',
'8': 'tuv',
'9': 'wxyz',
}

def word_numbers(input):
input = str(input)
ret = ['']
for char in input:
letters = digit_map.get(char, '')
ret = [prefix+letter for prefix in ret for letter in letters]
return ret
 The granting of a pardon is an imputation of guilt, and the acceptance a confession of it. 




Reply



Messages In This Thread
Bruteforce - by ErGingerbreadMandude - August 2, 2015 at 7:54 am
RE: Bruteforce - by vorlon13 - August 2, 2015 at 9:09 am
RE: Bruteforce - by Aractus - August 2, 2015 at 9:18 am
RE: Bruteforce - by vorlon13 - August 2, 2015 at 9:21 am
RE: Bruteforce - by ErGingerbreadMandude - August 2, 2015 at 9:33 am
RE: Bruteforce - by Alex K - August 2, 2015 at 9:47 am
RE: Bruteforce - by Aoi Magi - August 2, 2015 at 10:15 am
RE: Bruteforce - by ErGingerbreadMandude - August 2, 2015 at 10:48 am
RE: Bruteforce - by LastPoet - August 2, 2015 at 10:55 am
RE: Bruteforce - by ErGingerbreadMandude - August 2, 2015 at 11:16 am
RE: Bruteforce - by LastPoet - August 2, 2015 at 2:56 pm
RE: Bruteforce - by ErGingerbreadMandude - August 2, 2015 at 3:15 pm
RE: Bruteforce - by Ravenshire - August 2, 2015 at 3:17 pm
RE: Bruteforce - by LastPoet - August 2, 2015 at 3:25 pm
RE: Bruteforce - by emjay - August 2, 2015 at 3:44 pm
RE: Bruteforce - by Alex K - August 2, 2015 at 4:59 pm
RE: Bruteforce - by ErGingerbreadMandude - August 2, 2015 at 3:41 pm
RE: Bruteforce - by bennyboy - August 9, 2015 at 8:59 am



Users browsing this thread: 1 Guest(s)