in reply to One Zero variants_without_repetition
some fun, at least for me!
Oha$_ = "00111"; do { print "$_\n"; } while ( s/(1*?)(0*?)01/$2${1}10/ ); 00111 01011 10011 01101 10101 11001 01110 10110 11010 11100
edit: feel free to change $2${1}10 with $2$1\Q10 :-)
In Section
Seekers of Perl Wisdom