My apologies for not being a little more descriptive.
I actually already have an array of elements. And these
examples are no where near what I am doing, but I am just trying
to keep my questions as basic as possible. I need to go
through the array and create new scalars based on those elements.
I could probably address this entire thing as a hash but I would
have to go back and redo a lot of other things plus I don't think
based on the way I am using the array that a hash would be as
efficient.
As you showed in your example $lname is known when
actually the only thing I have is $fname.
I need to create a scalar that is the word lname combined with
what is found as interpretted $fname ($$fname).
ie; $lnamedanny = mallory.
I thought I could accomplish this with $lname . $$fname = mallory
hence concatenating $lname with $$fname but I get errors on the
concatenation.. Maybe it doesn't like concatenating with interpret.
I know I can concatenate 2 scalars with no problems.
Danny
On 15/Oct/2001 19:24:57, Melvyn Sopacua wrote:
> I dunno why, Danny, seems like a hash is much easier, but here it goes:
>
> At 19:23 15-10-01, you wrote:
>
> >ok.. anyone know how to do this right off. Still working with
> >variable interpreting and now I need to create a scalar based on
> >it. ie;
> >
> >$fname=danny;
> >$$fname=test;
> >
> >Now I know the above will result in scalar $danny = test but I need
> >to create something like such.
> >
> >$$fname . $lname=mallory;
> >
> >To create a scalar called $dannylname and set to mallory but I
> >am getting concatenation errors on scalar assignment.
>
> $fullname=$fname.$lname;
> $$fullname='test';
> print $$fullname;
>
>
>
> >Any Ideas?
> >
> >Danny
> >
> >
> >
> >
> >
> >--------------------------------------------------------------------------------
> >For unsubscription of this list send an email to [EMAIL PROTECTED] with
> >email
> >data containing unsubscribe emailadd sambar
>
> ____________________________________________________
>
> </MELVYN>
>
> void wakeup()
> {
> for(long int cuppajava;drink();cuppajava++);
> }
>
> --------------------------------------------------------------------------------
> For unsubscription of this list send an email to [EMAIL PROTECTED] with email
> data containing unsubscribe emailadd sambar
>
>
--------------------------------------------------------------------------------
For unsubscription of this list send an email to [EMAIL PROTECTED] with email
data containing unsubscribe emailadd sambar