hotshot has asked for the wisdom of the Perl Monks concerning the following question:
But I'm sure there's a better way, am I right?my @tmp = &someonesFunc(); if (@tmp > 1) { # got an array # do something } else { # got a scalar # do something else }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: array or scalar, that's the question
by Juerd (Abbot) on Jan 01, 2002 at 21:48 UTC | |
|
Re: array or scalar, that's the question
by Aristotle (Chancellor) on Jan 01, 2002 at 23:56 UTC | |
|
Re: array or scalar, that's the question
by Parham (Friar) on Jan 01, 2002 at 21:38 UTC | |
by hotshot (Prior) on Jan 01, 2002 at 21:47 UTC | |
by Fastolfe (Vicar) on Jan 02, 2002 at 00:13 UTC | |
by Juerd (Abbot) on Jan 02, 2002 at 00:21 UTC | |
by Fastolfe (Vicar) on Jan 03, 2002 at 00:01 UTC | |
|
Re: array or scalar, that's the question
by count0 (Friar) on Jan 01, 2002 at 22:26 UTC |