From: "Sak .." Date: 2010-02-11T01:19:10+09:00 Subject: Re: How to change stdin separator (perl vs ruby) Stefan Lang wrote: > 2010/2/10 Sak .. : >> $/ = "%"; >> while ($article = ) { >> �#Iteration >> } >> >> >> I can write a equivalent code in ruby but not (by far) as efficient as >> perl. Someone knows how can I change the separator for iterate the stdin >> in ruby? > > STDIN.each_line("%") { |line| > # iteration > } > > Stefan Thanks Stefan for the answer, that's exactly what I need, thanks Xavier explanation is perfect. Thanks Daniel, good observation. -- Posted via http://www.ruby-forum.com/.