in reply to Re: Printing a hollow square of Asterisks
in thread Printing a hollow square of Asterisks

this code doesnt output anything??
  • Comment on Re^2: Printing a hollow square of Asterisks

Replies are listed 'Best First'.
Re^3: Printing a hollow square of Asterisks
by ww (Archbishop) on Mar 04, 2009 at 15:12 UTC

    Maybe you thought the something in

    if( something ){
    was an actual instruction or variable?

    If so, use strict; use warnings; would have disabused you of that notion.

Re^3: Printing a hollow square of Asterisks
by Anonymous Monk on Mar 04, 2009 at 14:40 UTC
    Yes it does.
    $ perl test.pl |od -ta 0000000 sp sp sp sp nl sp sp sp sp nl sp sp sp sp nl s +p 0000020 sp sp sp nl 0000024 $ perl test.pl |od -tx1 0000000 20 20 20 20 0a 20 20 20 20 0a 20 20 20 20 0a 20 0000020 20 20 20 0a 0000024 $
    You're supposed to replace something with a simple expression that evaluates to true when you want to print spaces.