http://www.perlmonks.org?node_id=74880


in reply to Short (and clever?) CSV-to-AoA

Just to show another way (which I wouldn't actually suggest using due to the memory requirements, though it doesn't really use much more memory than some of other solutions suggested that turned out to be solutions for the wrong problem):

use mapcar; my @AoA= mapcar{[@_]}map{[split]}<DATA>;
(requires mapcar -- map for more than one list)

        - tye (but my friends call me "Tye")