Skip to content

Instantly share code, notes, and snippets.

@lynn
lynn / random-rhymes.py
Last active January 7, 2018 21:09
Turn English text into nonsense that sounds like the input
from collections import defaultdict
import fileinput
import random
import re
common = """the of and to a in for is on that by this with
i you it not or be are from at as your all have an was we
will can us i'm it you're i've my of""".split()
pronounce = {}