Closed T0rkman closed 4 years ago
pydictor's combination function -char
is exponentiation.
so it's result is 16^5=1048576
, not 16 choose 5=4368
.
I'm afraid pydictor doesn't work as well as you think, you need disorder wordlist.
that's example code:
#!/usr/bin/env python
# coding: utf-8
import itertools
def nCk(n, k):
return list(itertools.combinations(n, k))
print(nCk("apgny035oz2_.iml", 5))
My create wordlist start (head) oba. characters is totally 16 (letters, numbers and special symbols) Program needs to choose 5 out of 16 characters for combination. According to my calculation, this combination may be correctly listed in 4,368 different ways. Your program has more than 1 million results for this character length. Also, even though I make the character min length 5 max 5 the result is wrong. This error isn't just in these characters. What I want to say is that there is a combination error in the program. I would be glad if you fix it. Calculator= https://hizliresim.com/aYUJmU Program Combination= https://hizliresim.com/h8VjlO