# Simplifying/negating propcalc formula

I have some code to generate randomized boolean formulas involving AND, OR, and IMPLIES for use in student assessments:

props = [propcalc.formula(l) for l in "PQRS"]
ops = ["&","|","->"]
for _ in range(3):
shuffle(props)
shuffle(ops)
p = props.pop()
q = props.pop()