From: Florian Frank Date: 2005-03-11T07:51:30+09:00 Subject: Re: very slow IO (STDIN.gets and puts) on Linux, ruby 1.8.2_pre3 MiG wrote: >test.rb: >#!/usr/bin/ruby >while gets >end > >$ time ./test.rb < data.dat >./test.rb < data.dat 11,51s user 0,31s system 86% cpu 13,598 total > > > > Well, Ruby assigns the line string to $_, if you use gets that way. So Ruby has to construct an object for every line. Perhaps PHP doesn't do that? -- Florian Frank