Correct Answer - Option 3 : XOR gate
Explanation:
A room has a fan with 2 switches. The fan can be turned on by any switch regardless of the position of the second switch.
According to the above-mentioned statement, one switch needed to be in ON condition to switch ON the fan. Hence XOR gate logic can be used to implement the above situation.
x ⊕ y = x̅.y + x.y̅
XOR: Truth Table
INPUT
|
OUTPUT
|
x
|
y
|
x ⊕ y
|
0
|
0
|
0
|
0
|
1
|
1
|
1
|
0
|
1
|
1
|
1
|
0
|
The full form of the Ex-OR gate is the Exclusive-OR gate. the output of the Ex-OR gate is ‘1’ when only one of the two inputs is ‘1’. And it is zero when both inputs are the same.
The output of the Ex-OR gate is ‘1’ when an odd number of ones present at the inputs. Hence, the output of the Ex-OR gate is also called an odd function.