RE: variable definition error not caught when using strict and warnings

2012-11-09 Thread Nemana, Satya
From: Rob Dixon [rob.di...@gmx.com] Sent: 09 November 2012 17:17 To: beginners@perl.org Cc: Nemana, Satya Subject: Re: variable definition error not caught when using strict and warnings On 09/11/2012 17:08, Nemana, Satya wrote: > Hi > > I am

Re: variable definition error not caught when using strict and warnings

2012-11-09 Thread Rob Dixon
On 09/11/2012 17:08, Nemana, Satya wrote: Hi I am a little confused with this program Program: use strict; use warnings; if ($999 == 1056) { print ("\nequal"); } else { print ("\nnot equal"); } What I expect: Perl to throw me an error as $999 variable is not defined, but perl execu

Re: variable definition error not caught when using strict and warnings

2012-11-09 Thread Andy Bach
On Fri, Nov 9, 2012 at 11:08 AM, Nemana, Satya wrote: > > if ($999 == 1056) > { > print ("\nequal"); > } > else > { > print ("\nnot equal"); > } > > What I expect: Perl to throw me an error as $999 variable is not defined, > but perl executes the code with a warning.(I don't expect the co

Re: variable definition error not caught when using strict and warnings

2012-11-09 Thread Robert Wohlfarth
On Fri, Nov 9, 2012 at 11:08 AM, Nemana, Satya wrote: > Program: > use strict; > use warnings; > > if ($999 == 1056) > { > print ("\nequal"); > } > else > { > print ("\nnot equal"); > } > > What I expect: Perl to throw me an error as $999 variable is not defined, > but perl executes the c