Re: passing an array and a hash to a subroutine.

2002-11-21 Thread John W. Krahn
David Buddrige wrote: > > Hi all, Hello, > I want to write a subroutine that takes an array and a hash as input > parameters and then does some work on them. I can't seem to determine > how to do this however; it seems that with a subroutine, all you can > pass is a single array ( which appears

Re: passing an array and a hash to a subroutine.

2002-11-21 Thread Sudarshan Raghavan
On Thu, 21 Nov 2002, David Buddrige wrote: > > Hi all, > > I am writing a subroutine which is intended to take an array of strings, > and concatenate each string in the array into a single [very long] string. > > > The subroutine is listed below. > > My problem is that for some reason when I

RE: passing an array and a hash to a subroutine.

2002-11-21 Thread Timothy Johnson
foreach(sort keys %{$hRef}){ print " $_ => $hRef->{$_}\n"; } print "\$scalar = \"$scalar\"\n"; } ############ -----Original Message- From: David Buddrige To: [EMAIL PROTECTED] Sent: 11/20/02 10:32 PM Subject: Re: passi

Re: passing an array and a hash to a subroutine.

2002-11-20 Thread David Buddrige
Hi all, I have figured out the solution to the problem below is to use an array of references to the various objects that I want to pass into the subroutine. thanks guys David. David Buddrige wrote: Hi all, I want to write a subroutine that takes an array and a hash as input parameters and

Re: passing an array and a hash to a subroutine.

2002-11-20 Thread David Buddrige
Hi all, I am writing a subroutine which is intended to take an array of strings, and concatenate each string in the array into a single [very long] string. The subroutine is listed below. My problem is that for some reason when I print out the variable "$single_comment_line", rather than get