- or download this
my (undef, @headings) = split ' ', first {/^\s*AUID/} @lines;
- or download this
my @headings = splice @{[
split ' ', (grep /^\s*AUID/, @lines)[0] ]}, 1;
- or download this
my @headings = splice @{[ split ' ', first {/^\s*AUID/} @lines ]}, 1;
- or download this
my @headings = map {/(?!^\s*AUID)\s(\S+)/g} first {/^\s*AUID/} @lines;
- or download this
my @headings = (first {/^\s*AUID/} @lines)=~/(?!^\s*AUID)\s(\S+)/g;
- or download this
use warnings;
use strict;
...
my (undef, @headings) = split ' ', first {/^\s*AUID/} @lines;
is_deeply \@headings, \@expect or diag explain \@headings;
}