1.

C) if x1=true,x2=true, x3=false then find x4X4= !(x1) && (x2|| !(x3))&&x1​

Answer»

Required ANSWER:-

Given:

To Find:

  • x4 if x4 = !(x1) && (x2 || !(x3)) && x1

Solution:

Given,

!(x1) && (x2 || !(x3)) && x1

= not true && (true || not false) && true [Putting the VALUES.]

= false && (true || true) && true [not true = false and not false = true]

= false && true && true [true or true is true as one condition is true]

= (false && true) && true

= false && true [false as one condition is false]

= false [Again false as one condition is false]

>> x4 = false

Answer:

  • x4 = false

Note:

  • RESULT is always true if any one condition is true (In case of logical or). If all condition is false, result is false.

  • Result is true if all the condition is true (In case of logical and). If any one condition is false, result is false.


Discussion

No Comment Found