Question

Boolean evaluation: The two expressions below are logically equivalent. Give a set of values for x,...

Boolean evaluation: The two expressions below are logically equivalent. Give a set of values for x, y and z when both boolean expressions produce a result of TRUE.

• Expression 1: (! ((x % 2 == 0) && (y > z)))

• Expression 2: (! (x % 2 == 0) || !(y > z))

I am unsure how to do this- can I get an explanation?

Homework Answers

Answer #1
x is odd, and y and z values does not matter.
if this condition satisfies then these expressions always gives a result of TRUE

example:
-----------
x = 7, y = 2, z = 3

1)
(!((x % 2 == 0) && (y > z)))
=>  (!((3 % 2 == 0) && (2 > 3)))
=>  (!((false) && (false)))
=>  !(false)
=>  true

2)
(!(x % 2 == 0) || !(y > z))
=>  (!(7 % 2 == 0) || !(2 > 3))
=>  (!(false) || !(false))
=>  true || true
=>  true
Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
1) Convert the point (x,y,z)=(−2,5,3) to spherical coordinates. Give answers as positive values, either as expressions,...
1) Convert the point (x,y,z)=(−2,5,3) to spherical coordinates. Give answers as positive values, either as expressions, or decimals to one decimal place. (ρ,θ,ϕ)= 2) Convert the point (r,θ,z)=(2,2π,4) to Cartesian coordinates. Give answers either as expressions, or decimals to at least one decimal place. (x,y,z)= 3) Convert the point (ρ,θ,ϕ)= (5,5π/3,3π/4) to Cartesian coordinates. Give answers either as expressions, or decimals to at least one decimal place. (x,y,z) =
For table shown in figure 1 construct (a) a Boolean expression having the given table as...
For table shown in figure 1 construct (a) a Boolean expression having the given table as its truth table and (b) a circuit having the given table as its input/output table. (10 points) Figure 1: Truth table 6. Find the Boolean expressions for the circuits in figure 2 and show that they are logically equivalent when regarded as statement forms.(16 points) Figure 2: Circuits 7. Let R(m, n) be the predicate “If m is a factor of n 2 then...
Prove the following properties of Boolean algebras. Give a reason for each step. 1.(x.y)+(x′.z)+(x′.y.z′)=y+(x′.z) 2.x.y+x′=y+x′.y′ 3.x.y+y.z.x′=y.z+y.x.z′...
Prove the following properties of Boolean algebras. Give a reason for each step. 1.(x.y)+(x′.z)+(x′.y.z′)=y+(x′.z) 2.x.y+x′=y+x′.y′ 3.x.y+y.z.x′=y.z+y.x.z′ Prove that for any Boolean algebra: a. If x+y=0,then x=0 and y=0. b. x = y if and only if x . y′ + y .x′ = 0.
1) Develop a sum of products boolean expression corresponding to the truth table below. X Y...
1) Develop a sum of products boolean expression corresponding to the truth table below. X Y Z F 0 0 0 0 0 0 1 0 0 1 0 1 0 1 1 1 1 0 0 0 1 0 1 0 1 1 0 1 1 1 1 0 PLEASE EXPLAIN IN DETAIL
For this assignment you will implement a simple calculator or interpreter that reads arithmetic expressions from...
For this assignment you will implement a simple calculator or interpreter that reads arithmetic expressions from a file. Specifically, you will implement the following function: /* * Reads one arithmetic "expression" at a time from a file stream, computes, then * returns the result. If there are additional expressions in the file, they are * read and computed by successive calls to “calculator”. * * “Expressions” are groups of operations (add, subtract, multiply, divide). Your * calculator will read and...
Examine the computation formula for r, the sample correlation coefficient. (a) In the formula for r,...
Examine the computation formula for r, the sample correlation coefficient. (a) In the formula for r, if we exchange the symbols x and y, do we get a different result or do we get the same (equivalent) result? Explain your answer. The result is the same because the formula is not dependent on the symbols.The result is different because the formula is dependent on the symbols.    The result is different because the formula is not dependent on the symbols.The result is...
Examine the computation formula for r, the sample correlation coefficient. 1. In the formula for r,...
Examine the computation formula for r, the sample correlation coefficient. 1. In the formula for r, if we exchange the symbols x and y, do we get a different result or do we get the same (equivalent) result? Explain your answer. (A) The result is the same because the formula is not dependent on the symbols. (B) The result is different because the formula is not dependent on the symbols.     (C) The result is different because the formula is dependent...
Examine the computation formula for r, the sample correlation coefficient. (a) In the formula for r,...
Examine the computation formula for r, the sample correlation coefficient. (a) In the formula for r, if we exchange the symbols x and y, do we get a different result or do we get the same (equivalent) result? Explain your answer. The result is different because the formula is dependent on the symbols.The result is the same because the formula is dependent on the symbols.     The result is the same because the formula is not dependent on the symbols.The result is...
2. Expected Values: a) What is the formula for Expect[X] for some data set X, when...
2. Expected Values: a) What is the formula for Expect[X] for some data set X, when X is continuous and when X is discrete? b) Must an expected value of a data set be an element of that set? Why or why not? c) How is the expected value similar to or different from other measures of center such as the median or mode? d) What is the difference between theoretical expected values and experimental (sample) means? i. When is...
Examine the computation formula for r, the sample correlation coefficient. (a) In the formula for r,...
Examine the computation formula for r, the sample correlation coefficient. (a) In the formula for r, if we exchange the symbols x and y, do we get a different result or do we get the same (equivalent) result? Explain your answer. The result is different because the formula is dependent on the symbols. The result is the same because the formula is not dependent on the symbols. The result is different because the formula is not dependent on the symbols....