If all you have is regex s/.+/nail/
until(m/j{100}/){s/(j*)$/\1\n\1j/}; s/^(j{15})*$/fizzbuzz/gm; s/^(j{3})*$/fizz/gm; s/^(j{5})*$/buzz/gm; s/^(j+)$/length($1)/gme; print;
Warning: Do not try this (or any other perl coding) at home!
If all you have is regex s/.+/nail/
Warning: Do not try this (or any other perl coding) at home!