3 ms·
IMHO [[https://en.wikipedia.org/wiki/S-expression][Symbolic https://en.wikipedia.org/wiki/S-expression][Symbolic Expressions]] are... infinitely better. Exampl
by DKordic 10y ago
IMHO [[https://en.wikipedia.org/wiki/S-expression][Symbolic https://en.wikipedia.org/wiki/S-expression][Symbolic Expressions]] are... infinitely better.
Example:
'(iff (not (and (P 1) (P 2)))
(or (not (P 1)) (not (P 2))) )
- knight123 10y agoIt actually would not be too hard to add a separate parser for S-expressions; this would allow the existing "backend" tooling (converting to postfix, generating trees, filling tables, etc.) to be used unchanged. I actually think this would be a really powerful feature to add; thanks for the idea!
- brudgers 10y agoGreenspun's Tenth Rule: https://en.wikipedia.org/wiki/Greenspun%27s_tenth_rule https://en.wikipedia.org/wiki/Greenspun%27s_tenth_rule
- DKordic 10y agoI forgot to mention SMT-LIB[1] and pySMT[2]. I don't want to say their are optimal, I just think You might find it interesting. I think it would be even better with Curryed[0] Functions. As an example ``'(f a1 a2)'' is just a Syntactic Sugar for ``'((f a1) a2)''. Don't forget something like `help' in Python :) . [0]: https://en.wikipedia.org/wiki/Currying https://en.wikipedia.org/wiki/Currying [1]: http://www.smtlib.org/ http://www.smtlib.org/ [2]: https://github.com/pysmt/pysmt https://github.com/pysmt/pysmt
- brudgers 10y agoA Lisp might be a better language choice for that use case than Python. Nothing against Lisps or Python.