title: Python - create wordlist from given characters of that contain 4-5 letters and 5-6 numbers ONLY
body: <p>I'm looking to preform a dictionary attack and want to know how to create a wordlist that has every 10 letter permutation of the letters a-f and 2-9 (which I can do) WHEN every word contains 5 letters (a-f) and 5 numbers (2-9) OR 6 letters (a-f) and 4 numbers (2-9) ONLY (what I can't do).</p>
  
  <p>Here's what I have so far (from <a href="https://stackoverflow.com/questions/21559039/python-how-to-generate-wordlist-from-given-characters-of-specific-length">here</a>):</p>
  
  <pre><code>import itertools
  
  chrs = 'abcdef23456789'
  n = 2
  
  min_length, max_length = 10, 10
  
  for n in range(min_length, max_length+1):
      for xs in itertools.product(chrs, repeat=n):
          print ''.join(xs)
  </code></pre>
  
  <p>Thanks</p>