Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env python
- from __future__ import print_function
- from this import s, d
- from random import shuffle
- assert('I kid, because I love.' != False)
- print("\nAnd now for something completely different\n")
- txt = ''
- for char in s:
- char = d.get(char, char)
- txt += char
- txt = txt.split()
- shuffle(txt)
- current_line = ' '
- for word in txt:
- if len(current_line) + len(word) > 78:
- print(current_line)
- current_line = word
- else:
- current_line += ' ' + word
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement