---
title: "Short note: Ex-OR and Ex-NOR gate"
subject: "Basic Electrical and Electronics Engineering"
chapter: 3
key: "semester_1/basic_electrical_and_electronics_engineering:short-note-xor-xnor"
source: https://www.bctengineer.com/q/semester_1/basic_electrical_and_electronics_engineering/short-note-xor-xnor
site: BCT Engineering
---

# Short note: Ex-OR and Ex-NOR gate

Basic Electrical and Electronics Engineering · Chapter 3: Introduction to Electronics Engineering

- Asked in: 2081 Chaitra (new course), 3 marks
- Video: [Logic Gates : XOR and XNOR gates Explained | XOR and XNOR gate as Inverter](https://www.youtube.com/watch?v=Uf0KKh2zRuA) — ALL ABOUT ELECTRONICS
- Answer checked by Claude Opus 5.5 (high effort) on 2026-10-14
- Page: https://www.bctengineer.com/q/semester_1/basic_electrical_and_electronics_engineering/short-note-xor-xnor
- Whole chapter: https://www.bctengineer.com/md/semester_1/basic_electrical_and_electronics_engineering/chapter-3

## Question

Write a short note on Ex-OR and Ex-NOR gate.

## Short answer

Ex-OR (XOR) outputs 1 when inputs differ (A≠B), given by A⊕B = A B' + A' B. Ex-NOR (XNOR) is its complement, outputting 1 when inputs are equal (A=B), used in comparators. XOR is used in half adders, parity generators.

## Answer

**Ex-OR (XOR) gate.** It gives output 1 when its two inputs are **different** (odd number of 1s), and 0 when they are equal.

$$
Y=A\oplus B=A\bar B+\bar AB
$$

**Ex-NOR (XNOR) gate.** It is the complement of XOR. Output is 1 when the inputs are **equal**.

$$
Y=\overline{A\oplus B}=AB+\bar A\bar B
$$

| A | B | XOR | XNOR |
|---|---|---|---|
| 0 | 0 | 0 | 1 |
| 0 | 1 | 1 | 0 |
| 1 | 0 | 1 | 0 |
| 1 | 1 | 0 | 1 |

```text
 A --|=\\
     |  )>-- A xor B        XNOR: same, with a bubble
 B --|=//                     (small circle) at the output
```

**Applications:**
- XOR: half adder (sum $=A\oplus B$), binary adders/subtractors, parity generators and checkers, controlled inverter, binary-to-Gray code conversion.
- XNOR: equality (comparator) circuits, which give 1 when two bits are the same.

## Check yourself

The answer's key points as multiple-choice questions, with the correct option and why.

1. When does a two-input Ex-OR gate give output 1?
   A. When both inputs are equal
   B. When both inputs are 0
   C. Only when both inputs are 1
   D. When the inputs are different
   Answer: D. XOR gives 1 for an odd number of 1s, i.e. when the two inputs differ. (Key point: XOR behaviour)

2. How is the Ex-NOR gate related to Ex-OR, and what is its expression?
   A. It is the complement of XOR: Y = AB + A'B'
   B. It is the same as XOR: Y = AB' + A'B
   C. It is the complement of AND: Y = A' + B'
   D. It is the dual of OR: Y = A + B
   Answer: A. XNOR is the inverted XOR, giving 1 when the inputs are equal: Y = AB + A'B'. (Key point: XNOR definition)

3. Which application matches the XOR gate (sum output) and XNOR gate respectively?
   A. Half adder sum; equality comparator
   B. Equality comparator; half adder sum
   C. Memory cell; clock generator
   D. Inverter; amplifier
   Answer: A. Half adder sum = A xor B, while XNOR gives 1 when two bits are the same, so it is used in comparators. (Key point: Applications)

## Related in other subjects

- [Positive/negative logic; Ex-NOR using NOR](https://www.bctengineer.com/question.md?key=semester_3%2Fdigital_logic%3Apositive-negative-logic-xnor-nor) — Digital Logic, chapter 2, asked 2×
- [De Morgan; NOR gate from NAND gates](https://www.bctengineer.com/question.md?key=semester_3%2Fdigital_logic%3Ademorgan-importance-nor-from-nand) — Digital Logic, chapter 2
- [De Morgan; X-NOR using a universal gate](https://www.bctengineer.com/question.md?key=semester_3%2Fdigital_logic%3Ademorgan-xnor-universal-gate) — Digital Logic, chapter 2
- [TTL NOR gate; CMOS characteristics](https://www.bctengineer.com/question.md?key=semester_3%2Fdigital_logic%3Attl-nor-cmos-characteristics) — Digital Logic, chapter 10
