From: Jacob Fugal Date: 2005-07-16T07:26:49+09:00 Subject: Re: [QUIZ] Sampling (#39) On 7/15/05, Jacob Fugal wrote: > And, indeed: 49444444 / 5000000 = 9.8888888 On further examination, the expected length of a sample value would be[1]: (1..9).sum { |n| n * 9 * 10 ** (n - 10) } This evaluates to 8.888888889, or 9.888888889 characters per line, or an expected file size of 49444444.445 bytes. I think Ezra's output is right on. Jacob Fugal [1] My implementation of sum, for those interested. module Enumerable def sum self.inject(0) { |sum,n| sum + yield( n ) } end end