perl_lover has asked for the wisdom of the Perl Monks concerning the following question:
is giving me 20 (ie the length of array)@array = (1..20); @array1 = (2..10); print @array || @array1;
is giving me the second array completely. can anyone explain me how || operator will work for arrays@array = (); @array1 = (2..10); print @array || @array1;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Using || operator with arrays
by Errto (Vicar) on Feb 04, 2005 at 04:59 UTC | |
|
Re: Using || operator with arrays
by davido (Cardinal) on Feb 04, 2005 at 05:41 UTC | |
|
Re: Using || operator with arrays
by Tanktalus (Canon) on Feb 04, 2005 at 04:58 UTC | |
|
Re: Using || operator with arrays
by prasadbabu (Prior) on Feb 04, 2005 at 05:11 UTC | |
|
Re: Using || operator with arrays
by kprasanna_79 (Hermit) on Feb 04, 2005 at 05:13 UTC | |
by NetWallah (Canon) on Feb 04, 2005 at 05:29 UTC |