Sequential circuits have memory which allows the output to depend on the current and previous inputs. A basic memory element called a latch can be created using feedback in a combinational circuit. Two latches connected in a specific way create a flip-flop which changes state only on the rising or falling edge of a clock signal. For sequential circuits to operate reliably, there must be constraints on the timing of inputs including setup time and hold time relative to the clock edge.