A flip flop is a clocked binary storage device, that is, a device that stores
either a 0 or a 1. Under normal operation, that value will only change on
the appropriate transition of the clock.* The state of the system (that is,
what is in memory) changes on the transition of the clock. For some flip
flops, that change takes place when the clock goes from 1 to 0; that is
referred to as trailing-edge triggered. For others, that change takes place
when the clock goes from 0 to 1; that is referred to as leading-edge
triggered. What is stored after the transition depends on the flip flop data
inputs and what was stored in the flip flop prior to the transition.
Flip flops have one or two outputs. One output is the state of the
flip flop. If there are two, the other output is the complement of the state.