in reply to RE: (meonkeys: can't get every column)
in thread Locate char in a string

A thousand thanks. You helped me understand exactly what's going on here; you reminded me why I love this site/language! I shall repay you with a vote tomorrow. This works with your version:
#!/usr/bin/perl -w use strict; my @pos; my $line = "--------- --------- -------------- ---"; while ($line =~ / /g) { push @pos, pos($line); } print @pos;