From: Robert Klemme Date: 2009-02-25T21:26:41+09:00 Subject: Re: reading file to list 2009/1/19 William James : > André Thieme wrote: > That fails when numbers are separated by more than one space. > And what about leading or trailing space? Thsi is easily fixed: File.readlines("blob.txt").map{|line| line.scan(/\d+/).map{|s| s.to_i }} Btw, this will also read in the advertised Lisp notation with leading and trailing bracket per line. :-) Cheers robert -- remember.guy do |as, often| as.you_can - without end