UNCLASSIFIED

I tried that, and I get the following error... 

Possible attempt to separate words with commas at C:\test.plx line
 6.
'Start
test',
'Stop
test'

I'm running Active State Perl 5.6 on Windows 2000 Pro.

-----Original Message-----
From: Gary Stainburn [mailto:[EMAIL PROTECTED]
Sent: Monday, March 01, 2004 8:57 AM
To: Meidling, Keith, CTR, ISD; [EMAIL PROTECTED]
Subject: Re: Assigning elements to array (U)


On Monday 01 March 2004 1:54 pm, Meidling, Keith, CTR, ISD wrote:
> UNCLASSIFIED
>
> How can I assign elements to an array that have spaces in them?
>
> Say I have two elements that I want to put into an array, one is 'Start
> test' the other is 'stop test'. The only way I know how to do this is by
> the following.
>
> my @array;
>
> $array[0]="Start test";
> $array[1]="Stop test";
>
> Is there an easier way?

Yup

my @array=('Start test','Stop test');
-- 
Gary Stainburn
 
This email does not contain private or confidential material as it
may be snooped on by interested government parties for unknown
and undisclosed purposes - Regulation of Investigatory Powers Act, 2000     

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to