I am not sure that understand this task:
the tree must be just free of Any Imp or BiImp, but what is with all other cases?
E.g. case T() should return an BE. Could somebody explain me this task (what should be implemented here and how should like the result in terms of BE)?
Assignment 01: Boolean expressions --> Preprocessor
Re: Assignment 01: Boolean expressions --> Preprocessor
it’s clear now, I didn’t make intern preprocessing of expressions... 

Re: Assignment 01: Boolean expressions --> Preprocessor
Hi,
I still got problems in understanding the task. Can someone please explain how to solve implications?
I think just the replacement of logical values like this is not intended?:
I would realy appreciate some hints here.
Greetings, Daniel
I still got problems in understanding the task. Can someone please explain how to solve implications?
I think just the replacement of logical values like this is not intended?:
- T, T -> T
- T, F -> F
- F, T -> T
- F, F -> T
I would realy appreciate some hints here.
Greetings, Daniel
Re: Assignment 01: Boolean expressions --> Preprocessor
It's how the truth table for Imp looks like (I also thought in the beginning how to implement this values from table), but preprocessor should just make expressions free of any Imp or BiImp (Or, Not, And can be inside an expression also after preprocessing step). I understood it so (hope it's correct), once it happened, the task was easy to solve.
Re: Assignment 01: Boolean expressions --> Preprocessor
Hi,
thanks for the explanation! I solved it now too, finally ...
thanks for the explanation! I solved it now too, finally ...
Re: Assignment 01: Boolean expressions --> Preprocessor
Guys,
Can you please explain, Like
1. if as input I give imp(t,f) it will resolve to expression Or(Not(t), f), if i give imp(imp(t,f),f) or imp(imp(t,and(t,f)),f) it will just substitute imp using equivalent expression
will it not deduct the expressions and come to the result value as t or f?
2. what if And(Imp(t,f),f) is given as input it will expand the tree as And(Or(Not(t), f),f) or after expanding it will deduce to f also?
Can you please explain, Like
1. if as input I give imp(t,f) it will resolve to expression Or(Not(t), f), if i give imp(imp(t,f),f) or imp(imp(t,and(t,f)),f) it will just substitute imp using equivalent expression
will it not deduct the expressions and come to the result value as t or f?
2. what if And(Imp(t,f),f) is given as input it will expand the tree as And(Or(Not(t), f),f) or after expanding it will deduce to f also?
Re: Assignment 01: Boolean expressions --> Preprocessor
Your examples are correct: The preprocessor should not interpret expressions, but just prepare them so you could put the result into the interpreter from the previous task afterwards. So it should just replace for example And(Imp(t,f),f) by And(Or(Not(t), f),f), but not evaluate the resulting value.
Please also look at the test cases if you are unsure. I think they show pretty precisely what to do (and future tasks will also have you look at them if the specification is not 100% exact).
Please also look at the test cases if you are unsure. I think they show pretty precisely what to do (and future tasks will also have you look at them if the specification is not 100% exact).