while arr = gets
  arr = arr.split(",").map(&:to_i)
  len = arr[0..9].inject{|sum,i|sum + i}.to_f * arr[10] / (arr[10] + arr[11])
  i = 0
  while len > 0
    len -= arr[i]
    i += 1
  end
  puts i
end