How to create an hexa randomly numbers in python?
<p>I want to create a file of hexadecimal number where everyone is composed of 32 elements like this: </p>

<pre><code>ccddeeff8899aabb4455667fffffff33
e0370734313198a2885a308aaaaaaaa8
7354776f204f6e65204e696bbbbbbb6f
64976fbb4f6e6ee0cc681e6ccccccc77
</code></pre>

<p>I try by this code to create my numbers but I don't now how to have 32 elements for each number: </p>

<pre><code>   import random
   Plaintext_file = open("C:\\Users\\user\\Plaintexts.txt", "w")
   for i in range(5):
      i = random.randint(0, 16777215)
      print "%x" % i 
      Plaintext_file.write("%x \n" % i)
</code></pre>

<p>The result that I have:</p>

<pre><code>c39ea9
a737a0
d2d352
fcebf1
ade761
</code></pre>

<p>I would be very grateful if you could help. </p>