I was working on 11-1 on Conditionals and Control Flow. I did that little boolean riddle as follows. At what point did I go wrong in the precedence rules?
( 3 >= 3 && !(true || true) )
( 3 >= 3 && !(false) ) because true || true is in parentheses, I do it first
( 3 >= 3 && true ) I do ! next
( true && true ) 3 >= 3 is true
true because they're both true
Believe it or not, you did wayyy to much work for this lesson. You should start out with // ( 3 >= 3 && !(true || true) ) and while it is possible I am sure to add stuff to make this work you just need to leave it as is with the //. Secondly, all you need to make the bollean variable tircky equal to true or false is just equal it to true or false. So all in all:
// ( 3 >= 3 && !(true || true) )
boolean tricky = false; (or true whichever you choose I put false in mine)
This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.