http://qs1969.pair.com?node_id=184625


in reply to Formatting Into Columns

perldoc perlform

# Define the format, left align first, right align remainder format Schema = @<<<<<<<< @>>>>> @>>>>> @>>>>> $key, $s[0], $s[1], $s[2] . $~ = "Schema"; # Set the format we're going to use for $key (sort keys %hash) { @s = split(' ',$hash{$key}); write; }

Enjoy. (Consider in your next post specifying the exact format of $hash{$key}, in this case I've assumed it was a space-seperated string of numbers, but maybe it was an array-ref instead and you just didn't mention the join..)