Subject: Re: go to specific char in a file
From: Lee Jarvis <ljjarvis gmail.com>
Date: Sat, 19 Jan 2008 00:11:21 +0900
References: 287842287843287847
In-reply-to: 287847
Rudy Rusli wrote:
> I was just wondering if there's anyway to tackle it by using reg ex
Something like..
>> File.foreach('file') {|line| puts line.match(/^.{3}(.{5})/)[1] }
12AX3
123HG
?
Regards,
Lee
--
Posted via http://www.ruby-forum.com/.