Re: move array elements to hash

2011-04-17 Thread Jim Gibson
At 12:29 PM -0700 4/14/11, mark baumeister wrote: Hi, I am trying to move array elements (populated from the ) into a hash as pairs [i] and [i + 1] and then print them out using the code below. If I enter "bob" as the first element and hit enter I get the error messages below. I guess there are m

Re: move array elements to hash

2011-04-16 Thread John W. Krahn
mark baumeister wrote: Hi, Hello, I am trying to move array elements (populated from the) into a hash as pairs [i] and [i + 1] and then print them out using the code below. If I enter "bob" as the first element and hit enter I get the error messages below. I guess there are multiple problems

Re: move array elements to hash

2011-04-16 Thread Rob Dixon
On 14/04/2011 20:29, mark baumeister wrote: Hi, I am trying to move array elements (populated from the) into a hash as pairs [i] and [i + 1] and then print them out using the code below. If I enter "bob" as the first element and hit enter I get the error messages below. I guess there are multiple

Re: move array elements to hash

2011-04-16 Thread Shawn H Corey
On 11-04-14 03:29 PM, mark baumeister wrote: #create key - value pairs to go into a hash by first entering each into a list @k or @v print "input key/value pairs: first a key then return, then a value then return, etc. To stop entering key/value pairs type 'stop'\n"; while ($kv =) { chomp($kv

move array elements to hash

2011-04-16 Thread mark baumeister
Hi, I am trying to move array elements (populated from the ) into a hash as pairs [i] and [i + 1] and then print them out using the code below. If I enter "bob" as the first element and hit enter I get the error messages below. I guess there are multiple problems with my code. For one it appears th