We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
- Prepare
- Algorithms
- Recursion
- Password Cracker
- Discussions
Password Cracker
Password Cracker
Sort by
recency
|
141 Discussions
|
Please Login in order to post a comment
return 'WRONG PASSWORD' if match == login: return res + match return passwordCracker, (passwords, login(minara.18_, res + match + ' ')
there are so many test cases and it seems working but most of them are failing because of time limit.
`python
for x in passwords: if x == loginAttempt[:len(x)]: # print(x) if x == loginAttempt: return x res = passwordCracker(passwords, loginAttempt[len(x):]) if res != 0 and 'WRONG PASSWORD' not in res: return x +' '+ res else: continue return 'WRONG PASSWORD'`
`if match is None: return 'WRONG PASSWORD' if match == login:hak_goswami return res + match
Does not use up stack space since we use a trampoline
return , (passwords, login[len(match):], res + match + ' ')
`if match is None: return 'WRONG PASSWORD' if match == login:hak_goswami return res + match
Does not use up stack space since we use a trampoline
return , (passwords, login[len(match):], res + match + ' ')
`if match is None: return 'WRONG PASSWORD' if match == login: return res + match
Does not use up stack space since we use a trampoline
return p, (passwords, login[len(match):], res + match + ' ')