in reply to Re: How to find start position of each column
in thread How to find start position of each column

while ($firstrow =~ /(<\w>)/g) { push @columnpos, pos($firstrow) - length($1); }

You could use a look-ahead to avoid doing the capture, length and subtraction.

push @columnpos, pos $firstrow while $firstrow =~ m{(?=<\w>)}g;

I hope this is of interest.

Cheers,

JohnGG