T
Thomas Reat
I have a perl script that must take some boolean logic as input.
Something like:
((a || b) & !c) || d || (e && f)
Is there any module out there that can help me parse this? And
evaluate it as well?
Ideally I would pass it the expression and a hash (or callback) to get
the values of each variable. And it returns the value of the whole
expression. But if there's nothing that does that, I'm interested in
anything that helps with this.
Something like:
((a || b) & !c) || d || (e && f)
Is there any module out there that can help me parse this? And
evaluate it as well?
Ideally I would pass it the expression and a hash (or callback) to get
the values of each variable. And it returns the value of the whole
expression. But if there's nothing that does that, I'm interested in
anything that helps with this.