whatahitson has asked for the wisdom of the Perl Monks concerning the following question:
Hi. I have an array, @values containing coordinates. And entire array prints like this:
-0.709999984318709,60.690000003554324 -1.409999984834652,60.710000003710384 -1.389999984788378,60.970000003922536 -0.679999984264137,60.950000003761929 -0.709999984318709,60.690000003554324
but each element is actually a string with both lat and long, separated by a comma. I want to split this into two arrays, one that stores all my longitudes, and another that stores all of my latitudes. How can I do this?
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Splitting arrays
by choroba (Cardinal) on Jun 04, 2013 at 12:12 UTC | |
|
Re: Splitting arrays
by rjt (Curate) on Jun 04, 2013 at 12:10 UTC | |
|
Re: Splitting arrays
by BillKSmith (Monsignor) on Jun 04, 2013 at 13:43 UTC | |
|
Re: Splitting arrays
by jnyman (Acolyte) on Jun 04, 2013 at 12:24 UTC |