|
>>> print dp.parse(r'(DRS([x],[walks(x)]) + DRS([y],[runs(y)]))')
(DRS([x],[walks(x)]) + DRS([y],[runs(y)]))
>>> print dp.parse(r'(DRS([x,y],[walks(x), jumps(y)]) + (DRS([z],[twos(z)]) + DRS([w],[runs(w)])))')
(DRS([x,y],[walks(x), jumps(y)]) + (DRS([z],[twos(z)]) + DRS([w],[runs(w)])))
>>> print dp.parse(r'((DRS([],[walks(x)]) + DRS([],[twos(x)])) + DRS([],[runs(x)]))')
((DRS([],[walks(x)]) + DRS([],[twos(x)])) + DRS([],[runs(x)]))
>>> print dp.parse(r'((DRS([],[walks(x)]) + DRS([],[runs(x)])) + (DRS([],[threes(x)]) + DRS([],[fours(x)])))')
((DRS([],[walks(x)]) + DRS([],[runs(x)])) + (DRS([],[threes(x)]) + DRS([],[fours(x)])))
>>> print dp.parse(r'(DRS([],[walks(x)]) + runs(x))')
(DRS([],[walks(x)]) + runs(x))
>>> print dp.parse(r'(walks(x) + DRS([],[runs(x)]))')
(walks(x) + DRS([],[runs(x)]))
>>> print dp.parse(r'(walks(x) + runs(x))')
(walks(x) + runs(x))
|