From: Vell Date: 2008-02-06T01:39:57+09:00 Subject: Re: String scanning woes :( On Feb 5, 6:40 am, William James wrote: > On Feb 4, 6:50 pm, Vell wrote: > > > emails = File.open("/users/lem/desktop/test/ > > POCs_DNB.txt","r").readlines.map! {|x| x.chomp} > > email.scan(/\S+/) > > First you say "emails"; then you say "email". > This is not code that will run. > > Didn't you copy and paste?  Don't tell us that you > retyped the code because you were eager for the chance > to introduce errors. > I'm a beginner, lighten up James. > p IO.readlines( "data" ).map{|x| x.strip } > p IO.read( "data" ).split > p IO.read( "data" ).scan(/\S+/)