> -----Original Message----- > From: lists user [mailto:[EMAIL PROTECTED] > Sent: Sunday, August 26, 2007 20:01 > To: beginners perl > Subject: a division warning > > I run a perl command below, > > perl -Mstrict -Mwarnings -e 'eval {my $x=3;my > $y=$x-3;$x/$y};print "hello"' > Useless use of division (/) in void context at -e line 1. > hello > > I'm confused about the first warning.What's it?thanks. You have the division, but there is no assignment for $x/$y. So by adding $z = $x/$y; , then this msg will go away.
Wags ;) > > -- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > http://learn.perl.org/ > > > ********************************************************************** This message contains information that is confidential and proprietary to FedEx Freight or its affiliates. It is intended only for the recipient named and for the express purpose(s) described therein. Any other use is prohibited. ********************************************************************** -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/