Latches are asynchronous electronic logic circuits with two stable output states. There are four main types of latches: D, T, SR, and JK latches. An SR latch has two inputs - SET (S) and RESET (R) - and two complementary outputs (Q and Q'). The state of the latch depends on whether input S or R is activated. A D latch similarly has one data input and two complementary outputs, but removes invalid states that can occur in an SR latch. Latches can be either active-high or active-low, depending on whether a high or low input triggers a state change.