[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [FWP] Is this fun? What's going on?



At 17:17 -0700 8/5/99, Vicki Brown wrote:
> #!/usr/bin/perl
>
> foreach (@INC) {
>   print
>   print "\n"
> }
>
>
> The results are not what I expected...

At 17:31 -0700 8/5/99, lr@hpl.hp.com wrote:
> Why not?  You are telling it to print the value of printing a newline.

At 20:31 -0400 8/5/99, Michael Assels wrote:
> ;
> ;-)

At 17:52 -0700 8/5/99, Randal L. Schwartz wrote:
> The results are exactly what I expected.

At 21:28 -0400 8/5/99, Rich Bowen wrote:
> Cute. Looks like the sort of thing that I'd get turned in by a student,
> and stare at for hours trying to figure out what was going wrong!



Some of you are losing your sense of silliness... some of you "got it".
This isn't c.l.p.-mod it's fwp. The results are perhaps what you expected
if you planned it that way...   But put yourself in the position of not
having planned it. Hint - I was expecting a syntax error. Specifically, I
was tracking down a problem that required me to need to generate at least
one syntax error, and it seemed the simplest way to do that would be to
take out a semicolon.  It was the wrong semicolon :-)
-- --
       |\      _,,,---,,_       Vicki Brown <vlb@cfcl.com>
 ZZZzz /,`.-'`'    -.  ;-;;,_   Journeyman Sourceror: Scripts & Philtres
      |,4-  ) )-,_. ,\ (  `'-'  P.O. Box 1269  San Bruno  CA  94066
     '---''(_/--'  `-'\_) http://www.cfcl.com/~vlb  http://www.macperl.com

==== Want to unsubscribe from Fun With Perl?  Well, if you insist...
==== Send email to <fwp-request@technofile.org> with message _body_
====   unsubscribe