# What is Digital Logic Gate?

## Universal logic gates symbol and brief descriptions

A digital logic gate is a fundamental building block of digital electronics that performs a specific logical operation on one or more inputs and produces an output. Digital logic gates are used to build more complex circuits that perform various functions, such as processing and storing data, controlling devices, and performing mathematical operations.

There are several types of digital logic gates, including AND, OR, NOT (also known as NOR), NAND, and XOR. Each type of gate performs a specific logical operation and has a specific truth table that defines the output for different combinations of inputs.

Digital logic gates are constructed using transistors, which are electronic devices that control the flow of current through a circuit. The output of a digital logic gate is determined by the state of the inputs and the type of logical operation being performed.

Digital logic gates are essential components of digital circuits and are used in a wide range of electronic devices, including computers, smartphones, and other electronic devices. They are an important part of the design and operation of digital systems and are used in many different applications, including data processing, communication, and control.

Digital logic gates can be categorized into two types See the Figure

## Basic Gates

### AND gate

An AND gate is a digital logic gate that performs a logical AND operation. It has two or more inputs and one output, and the output is “true” (1) only when all of the inputs are “true” (1).

show an image of an AND gate symbol:

The AND gate is represented by a rectangle with a dot inside, with the inputs at the left side of the rectangle and the output at the right side. The output of the AND gate is “true” (1) only when all of the inputs are “true” (1). If any of the inputs is “false” (0), the output will be “false” (0).

For example, if the inputs to the AND gate are “true” (1) and “true” (1), the output will be “true” (1). If either of the inputs is “false” (0), the output will be “false” (0).

The AND gate is a basic building block in digital circuits and is often used in conjunction with other gates to create more complex circuits. It is a useful tool for performing logical AND operations on multiple inputs.

### OR gate

An OR gate is a digital logic gate that performs a logical OR operation. It has two or more inputs and one output, and the output is “true” (1) when any of the inputs is “true” (1).

The OR gate is represented by a rectangle with a plus sign inside, with the inputs at the left side of the rectangle and the output at the right side. The output of the OR gate is “true” (1) when any of the inputs is “true” (1). If all of the inputs are “false” (0), the output will be “false” (0).

For example, if the inputs to the OR gate are “true” (1) and “false” (0), the output will be “true” (1). If both inputs are “false” (0), the output will be “false” (0).

The OR gate is a basic building block in digital circuits and is often used in conjunction with other gates to create more complex circuits. It is a useful tool for performing logical OR operations on multiple inputs.

### NOT gate

A NOT gate, also known as a NOR gate, is a digital logic gate that performs a logical NOT operation. It has one input and one output, and the output is the inverse of the input.

The NOT gate is represented by a triangle with a circle inside, with the input at the triangle end and the output at the circle end. The output of the NOT gate is “true” (1) when the input is “false” (0), and vice versa.

For example, if the input to the NOT gate is “true” (1), the output will be “false” (0). If the input is “false” (0), the output will be “true” (1).

The NOT gate is a basic building block in digital circuits and is often used in conjunction with other gates to create more complex circuits. It is a useful tool for inverting the output of other logic gates or for providing a “reset” function in a circuit.

## Universal Gates

### NAND gate

A NAND gate is a digital logic gate that performs a logical NAND operation. It has two or more inputs and one output, and the output is the inverse of the output of an AND gate.

The NAND gate is represented by a rectangle with a dot inside and a small circle at the output, with the inputs at the left side of the rectangle and the output at the right side. The output of the NAND gate is “true” (1) when any of the inputs is “false” (0). If all of the inputs are “true” (1), the output will be “false” (0).

For example, if the inputs to the NAND gate are “true” (1) and “false” (0), the output will be “true” (1). If both inputs are “true” (1), the output will be “false” (0).

The NAND gate is a basic building block in digital circuits and is often used in conjunction with other gates to create more complex circuits. It is a useful tool for performing logical NAND operations on multiple inputs.

### NOR gate

A NOR gate is a digital logic gate that performs a logical NOR operation. It has two or more inputs and one output, and the output is the inverse of the output of an OR gate.

The NOR gate is represented by a rectangle with a plus sign inside and a small circle at the output, with the inputs at the left side of the rectangle and the output at the right side. The output of the NOR gate is “true” (1) when all of the inputs are “false” (0). If any of the inputs is “true” (1), the output will be “false” (0).

For example, if the inputs to the NOR gate are “true” (1) and “false” (0), the output will be “false” (0). If both inputs are “false” (0), the output will be “true” (1).

The NOR gate is a basic building block in digital circuits and is often used in conjunction with other gates to create more complex circuits. It is a useful tool for performing logical NOR operations on multiple inputs.

### XOR / EX-OR gate

An XOR gate, also known as an exclusive OR gate, is a digital logic gate that performs a logical exclusive OR operation. It has two or more inputs and one output, and the output is “true” (1) when an odd number of inputs are “true” (1).

The XOR gate is represented by a rectangle with a plus sign inside and a small circle at the output, with the inputs at the left side of the rectangle and the output at the right side. The output of the XOR gate is “true” (1) when an odd number of inputs are “true” (1). If an even number of inputs are “true” (1), the output will be “false” (0).

For example, if the inputs to the XOR gate are “true” (1) and “false” (0), the output will be “true” (1). If both inputs are “true” (1), the output will be “false” (0).

The XOR gate is a basic building block in digital circuits and is often used in conjunction with other gates to create more complex circuits. It is a useful tool for performing logical exclusive OR operations on multiple inputs.

### XNOR / EX-NOR gate

An XNOR gate, also known as an exclusive NOR gate, is a digital logic gate that performs a logical exclusive NOR operation. It has two or more inputs and one output, and the output is “true” (1) when an even number of inputs are “true” (1).

The XNOR gate is represented by a rectangle with a plus sign inside and two small circles at the output, with the inputs at the left side of the rectangle and the output at the right side. The output of the XNOR gate is “true” (1) when an even number of inputs are “true” (1). If an odd number of inputs are “true” (1), the output will be “false” (0).

For example, if the inputs to the XNOR gate are “true” (1) and “false” (0), the output will be “false” (0). If both inputs are “true” (1), the output will be “true” (1).

The XNOR gate is a basic building block in digital circuits and is often used in conjunction with other gates to create more complex circuits. It is a useful tool for performing logical exclusive NOR operations on multiple inputs.