4 ms·
Random binary dumps aren't what they used to be. You should manually decode some 8-bit ascii by hand: $ python Python 2.7.6 Type "help", "copyright
by jerf 11y ago
Random binary dumps aren't what they used to be. You should manually decode some 8-bit ascii by hand:
$ python
Python 2.7.6
Type "help", "copyright", "credits" or "license" for more information.
>>> import random
>>> print(''.join([chr(random.randint(32,255))
for x in range(50)]).decode("latin-1"))
¿IBÄõq½¦Áºn}@õÖhzUÌÓQ£m5ë¢ümÇ®=ÇÆªLÛHt
Now that's quality random binary garbage.
- beefhash 11y agoMedium-quality random binary garbage. randint is an alias for randrange,[1] which produces "slightly uneven distributions" according to the docs before version 3.2.[2] [1] https://docs.python.org/3/library/random.html?highlight=random#random.randint https://docs.python.org/3/library/random.html?highlight=rand... (There's no such hint for the 2.x docs, but I'm guessing it was just added later for clarification) [2] https://docs.python.org/3/library/random.html?highlight=random#random.randrange https://docs.python.org/3/library/random.html?highlight=rand...