in reply to shift split grep question

#!/usr/bin/perl # https://perlmonks.org/?node_id=1226300 use strict; use warnings; my @lines = <<END =~ /.*\n/g; other stuff AUID \cIRA \cIDec \cILabel \cIV \cIB-V \cIComments more stuff END my @headings = (grep /^\s*AUID/, @lines)[0] =~ /\t(\S+)/g; use Data::Dump 'dd'; dd \@headings;