Re: Use of uninitialized value in numeric ne error



On 21 Dec 2007, at 10:43, lerameur wrote:

Hello and cheers to all,

hello


I wrote a small program and it does work, but I get this error message
every tim I run the script:
Use of uninitialized value in numeric ne (!=) at ./reverse_string.pl
line 11.
basically it is a menu and when the user type 99 as a choice, the
program ends


if like is a string the you can't do != as it is a numerical comparison

line 11 is:
while ( $line != 99){

more of the script would be handy - as it looks (at a quick glance) as if $line is null.


thanks
ken

Dan.



--
To unsubscribe, e-mail: beginners-unsubscribe@xxxxxxxx
For additional commands, e-mail: beginners-help@xxxxxxxx
http://learn.perl.org/



.



Relevant Pages

  • Re: WMI Logoff wont
    ... Tim ... > your script a shot, ... >> Can you try this script and see if the returnValue that get's echo'ed out ... >> nLogoff from 0 to 4 and see if that does the trick for you. ...
    (microsoft.public.win32.programmer.wmi)
  • Re: WMI Logoff wont
    ... >> your script a shot, ... >>> Can you try this script and see if the returnValue that get's echo'ed ... >>> dim outParams, inParams ...
    (microsoft.public.win32.programmer.wmi)
  • Re: WMI Logoff wont
    ... No the script does not work on the failing machine. ... Tim. ... >>> Scott McNairy ...
    (microsoft.public.win32.programmer.wmi)
  • Re: Moving the Windows Taskbar via script
    ... > Tim, you may be waiting a long time for an answer to do this ... could be called from script but, if it exists, I can't seem to find it. ... members of the ABD struct are required and all others are ignored. ... the taskbar screen coordinates with the sample code that you linked to. ...
    (microsoft.public.scripting.vbscript)
  • Re: Strange Windows 2000 Error
    ... that's one thing to consider BUT the error appears before the login ... script has a chance to run. ... Tim ... > their times with the domain controller. ...
    (microsoft.public.win2000.networking)