Logic gates are the basic building blocks of digital systems. The main logic gates are AND, OR, NOT, NAND, and NOR gates. Each gate has 1 or more inputs and 1 output, with the output determined by the inputs based on the gate's logic. NAND and NOR gates are called universal gates because combinations of them can be used to perform the logic of all the basic gates.