Your correct. Actually I was trying to pass that variable back when it was local to
the sub routine instead of assigning it to a variable outside the routine i.e
$process_data2=dateme( );
where process_data2 is either global or assigned as my OUTSIDE that particular routine.
Thanks,
JC
Flemm
jason corbett wrote:
I have a sub routine that I created called dateme.
when i run the sub routine, I am getting errors that Global symbol "$process_date" requires explicit package name at What gives?
Thanks,
JC
Here is the snipet
#---called from
dateme( );
#
Howdy all!
Thanks for everyone who gave suggestions on this.
I'm ending up doing hash since it seems the best way to do what I want:
my %x;
for(100..1,2) { $x{$_} = "... $_"; }
print "$x{1978} $x{57} Howdy!";
Thanks all!
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional
Dan Muey wrote:
>> You've got it, only, don't return anything.
>>
>> Here is a command-line example:
>>
>>perl -le'sub v{${$_} = ++$c for qw[x y z]} v; print "$x $y $z"'
>>
>> This is basically exactly what you have there. It's not
>> supposed to "return" variables, but rather "create" var
On Mon, Jul 28, 2003 at 03:23:10PM -0500, Dan Muey wrote:
> That what I'd say also except here I'm using a series of
> numbers for(100..1000) { } Each one has the same string
> except the number is different And then want to just declare
> them all with one call and use them as I want.
Nope.
Dan Muey wrote:
> Howdy list!
>
> I was wondering if it's possible to run a funtion and have it set a
> bunch of variables.
>
> As in variables I didn't declare before.
Yes, but don't do it.
>
> #/usr/bin/perl -w
>
> use strict;
>
> makevars(); # declares, and gives a value to $one $two $
It was Monday, July 28, 2003 when Dan Muey took the soap box, saying:
: > You've got it, only, don't return anything.
: >
: > Here is a command-line example:
: >
: >perl -le'sub v{${$_} = ++$c for qw[x y z]} v; print "$x $y $z"'
: >
: > This is basically exactly what you have there. It's no
> You've got it, only, don't return anything.
>
> Here is a command-line example:
>
>perl -le'sub v{${$_} = ++$c for qw[x y z]} v; print "$x $y $z"'
>
> This is basically exactly what you have there. It's not
> supposed to "return" variables, but rather "create" variables.
>
> Just a note