in reply to Print both elements in a compare
I tried this and get an uninitalized value error in the print
Are you sure the warnings comes from that line? The line you've shown produces "Use of uninitialized value in concatenation" (and not print), so maybe a different line is to blame?
Also I can recommend to use perl 5.10 or newer, it often tells you which variable was actually undefined.
That said your piece of code can produce such warnings when @array1 contains undef elements - what do you want to do in that case?
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Print both elements in a compare
by Anonymous Monk on Nov 01, 2010 at 19:05 UTC | |
by moritz (Cardinal) on Nov 01, 2010 at 22:19 UTC |