When a transistor is used as a switch in what two states is it operated?

on or off