OR Gate
beginner · combinational · 25 XP
Sign in to write your solution, run it in the simulator and submit it for grading.
Sign in or create a free account →Problem
OR Gate
Implement a 2-input OR gate. Output is high when **either or both** inputs are high.
**Truth Table**
| a | b | y |
|---|---|---|
| 0 | 0 | 0 |
| 0 | 1 | 1 |
| 1 | 0 | 1 |
| 1 | 1 | 1 |
Constraints
- Use a single assign statement with the | operator.
Examples
Input: a=0, b=0
Output: y=0
Input: a=1, b=0
Output: y=1
Common questions
- What does the OR Gate problem ask you to build?
- OR Gate Implement a 2-input OR gate. Output is high when **either or both** inputs are high. **Truth Table** | a | b | y | |---|---|---| | 0 | 0 | 0 | | 0 | 1 | 1 | | 1 | 0 | 1 | | 1 | 1 | 1 |
- What constraints does OR Gate have?
- Use a single assign statement with the | operator.
- What is an example input and output for OR Gate?
- Input a=0, b=0 gives output y=0.
- Which Verilog concepts does OR Gate practise?
- combinational, gates.