Help for this page

Select Code to Download


  1. or download this
    my @chunks = ($string =~ /(?|(?:((?:[^\n]*\n){19}[^\n]*)\n)|((?s:.*)))
    +/g);
    print Dumper @chunks[0];
    
  2. or download this
     Sequence (?|...) not recognized in regex; marked by <-- HERE in m/(?|
    + <-- HERE (?:((?:[^\n]*\n){19}[^\n]*)\n)|((?s:.*)))/.