Logic Gate Calculator

Simulate digital logic gates and see outputs for different input combinations.

Input Controls

Input A
Input B
Input C

Current State:

A=1B=0C=1

Two-Input Gates (A, B)

AND0

A AND B

OR1

A OR B

XOR1

A XOR B

NAND1

A NAND B

NOR0

A NOR B

XNOR0

A XNOR B

NOT Gates

NOT A0
NOT B1

Three-Input Gates (A, B, C)

AND30

A AND B AND C

OR31

A OR B OR C

XOR30

A XOR B XOR C

Majority1

At least 2 HIGH

Logic Gate Reference

AND

Output is 1 only when ALL inputs are 1

1 AND 1 = 1

OR

Output is 1 when ANY input is 1

1 OR 0 = 1

NOT

Inverts the input signal

NOT 0 = 1

XOR

Output is 1 when inputs are DIFFERENT

1 XOR 0 = 1

NAND

NOT of AND operation

1 NAND 1 = 0

NOR

NOT of OR operation

0 NOR 0 = 1