Transition

In reply to peter:

‘!’ is a logical not, sop ‘!2’ is ‘0’, not sure if that is what you want.

You can do

 bins d2 = (2=>3[=2]);

Which is nonconsecutive repetition 2=>3…=>2=>3. But there is no way to set a limit between repetitions