How to work with Two-dimensional arrays? 
Author Message
 How to work with Two-dimensional arrays?

 [courtesy cc of this posting sent to cited author via email]

In comp.lang.perl.misc,

:My program reads an unknown number of records. Each record belongs
:to a group which is known from the first char. I can't specify the
:current number of groups so I want to program flexible! If I could
:use a 2-dimensional array it would be very easy so I tried a
:Input looks like:
:I wish to have a function like
:push(myarr{substr($String,0,1)}, substr($String, 1));
:This syntax does not work! Am I wrong?


Read the Perl Data Structures Cookbook at



"...we will have peace, when you and all your works have perished--and
 the works of your dark master to whom you would deliver us.  You are a
 liar, Saruman, and a corrupter of men's hearts."  --Larry Wall in perl/taint.c, citing Theoden from LOTR

Tue, 14 Apr 1998 03:00:00 GMT  
 [ 1 post ] 

 Relevant Pages 

1. Weird Hash w/ n-dimensional two-dimensional array !!!!!!

2. Associative array of a two dimensional array

3. 2-dimensional array into 1 dimensional array?

4. Reading into a two-dimensional array from STDIN

5. two-dimensional arrays

6. how to build two dimensional array?

7. how to build two dimensional array?

8. Two dimensional array

9. Different ways of initialising a two dimensional array

10. Dynamic Two-Dimensional Array Creation?

11. two-dimensional arrays, lists, whatever

12. sort a two-dimensional array....


Powered by phpBB® Forum Software