Skip to content

Instantly share code, notes, and snippets.

@e-io
Created October 8, 2021 12:05
Show Gist options
  • Save e-io/d087d48695d1f41a1407a01578f7cfff to your computer and use it in GitHub Desktop.
Save e-io/d087d48695d1f41a1407a01578f7cfff to your computer and use it in GitHub Desktop.
ASCII and random characters
from random import randint
print('ASCII:')
for sym in range(128):
print(sym, f':c={sym:c}', sep='', end='\t')
print('\n\nRandom symbols:')
for i in range(100):
print(sym := randint(0, 0x11000 // 2), f':c={sym:c}', sep='', end='\t')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment