Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re^2: array of arrays

by Anonymous Monk
on Jun 12, 2017 at 01:23 UTC ( [id://1192552]=note: print w/replies, xml ) Need Help??


in reply to Re: array of arrays
in thread array of arrays

Hello Marshall:

I like your solution.. it does way with indices as you say. I copied it to my file and works great.

Now how would you do the same thing if the test_file.txt would be like this..??

1|10
1|20
1|30
1|40
1|50
2|15
2|25
2|35
3|1
3|2
3|3
3|4
3|5
3|6
3|7
3|8
3|9
3|10

Replies are listed 'Best First'.
Re^3: array of arrays
by AnomalousMonk (Archbishop) on Jun 12, 2017 at 04:40 UTC

    kevbot and Marshall have already given solutions that handle the  1|10 organization of data. What was wrong with these approaches? If you can identify and clearly explain shortcomings, I'm sure they can be addressed.


    Give a man a fish:  <%-{-{-{-<

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1192552]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others having a coffee break in the Monastery: (5)
As of 2024-04-23 07:23 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found