At 14.23 -0400 1999.06.10, Robert wrote: >I'm learning the examples from _Learning Perl on Win32 Systems_ using my >PowerBook. The following example does not work correctly. It appears that I >am incorrectly specifying that columnz is a variable. The script just >outputs words, right-justified, in a column of an arbitrary width. What am I >doing wrong? > >print "How many columns? "; >chomp ($columnz = <STDIN>); >print "Enter a list of words:\n"; >chomp (@list = <STDIN>); >foreach (@list) { > printf "%${columnz}s\n", $_; > } Looks fine, but your post has a problem. You say "The following example does not work correctly", without telling us what it is doing that is wrong. -- Chris Nandor mailto:pudge@pobox.com http://pudge.net/ %PGPKey = ('B76E72AD', [1024, '0824090B CE73CA10 1FF77F13 8180B6B6']) ===== Want to unsubscribe from this list? ===== Send mail with body "unsubscribe" to macperl-request@macperl.org