On Mon, Sep 12, 2011 at 12:12 PM, Josh Cheek <josh.cheek / gmail.com> wrote:
> pre =3D [[1.1, 2.2, 3.3], [4.1, 5.6, 6.8], [7.1, 8.7, 9.0], [10.0, 11.4,
> 12.6]]
>
> post =3D Array.new
> pre.each do |inner_array|
> =A0post << []
> =A0inner_array.each { |num| post.last << num.to_i }
> end

luv this inject code. hope matz can enhance inject further

 pre.inject([]) do |new_array,inner_array|
   new_array + [inner_array.map(&:to_i)]
 end
#=3D> [[1, 2, 3], [4, 5, 6], [7, 8, 9], [10, 11, 12]]

kind regards -botp