in reply to me & JAPH

I'm not "budding", per se...
use strict; sub _ { "#" . shift(@_) x $#_ . "#\n" } # first argument is copied as many times as there # are OTHER arguments (minus 1 due to $#_ and not @_). # a '#' is put on the front and back of this string. # this gets passed "#" or " ", and @__ and as we see # below, @__ has 28 elements, so this'll print 30 chars. my @__ = ('A'..'Z', $", '&'); # 'A' to 'Z', ' ', and '&' sub __ { "#", # a '#' $" x ((@__-@_)/2), # half the difference, that many spaces @_, # the arguments $" x ((@__-@_)/2), # half the difference, that many spaces "#\n" # a '#' and newline } # the goal of __() is to CENTER the text it's given s//#/; # put a # at the front of $_ print _($_,@__), # '###########' _($",@__), # '# #' __(@__[9,20,18,19,26]), # '# JUST #' __(@__[0,13,14,19,7,4,17]), # '# ANOTHER #' __(@__[15,4,17,11,26]), # '# PERL #' __(@__[7,0,2,10,4,17,26]), # '# HACKER #' _($",@__), # '# #' _($_,@__), # '###########'


japhy -- Perl and Regex Hacker