On Feb 2, 2008 11:05 PM, Todd Benson <caduceass / gmail.com> wrote:
> a.inject(a.first) {|m, e| e < m ? e : m}
> a.each_with_index {|v, i| s_indexes << i if v == a.min}


Sorry, these lines are supposed to be...

smallest = a.inject(a.first) {|m, e| e < m ? e : m}
a.each_with_index {|v, i| s_indexes << i if v <= smallest}

Todd