Forget what IRstuff says about bad practice, its actually quite common practice and nothing wrong with it, it has its uses.
The easiest 2 line code is as follows.
Pushbutton Trigger
---[P]-----------( )---
Trigger coil coil
--] [---]/[--+---( )---
Trigger coil |
--]/[---] [--+
The rising edge of the pushbutton turns on Trigger, then Trigger will make the circuit on branch one if coil is off, or break the circuit on branch 2 if coil is on, as its a one shot, the next scan coil will remain at the changed state.
Then coil can be used to energise a lamp or other indication so you know the status.