$<.each_line do |line|
  src = line.split(",").map(&:to_i)

  lens   = src[0...10]
  v1, v2 = src[10, 11]

  total_len = lens.inject(:+).to_f
  meet_time = total_len / (v1+v2)
  meet_spot = meet_time * v1

  advanced     = 0
  meet_section = lens.index{|l| advanced += l; advanced >= meet_spot}+1

  puts meet_section
end