n = gets.to_i p = gets.split.map(&:to_i) q = gets.split.map(&:to_i) r = p.map {|x| x / 1000.0} s = 1.0 ans = 0 1.upto(10**4) do |k| z = r.zip(q).map {|x, y| x*y} m, i = z.each_with_index.max ans += k * s * (m / 100.0) s *= 1 - m / 100.0 d = 1 - r[i] * q[i] / 100.0 r.each_with_index do |e, j| r[j] = if j == i r[j] * (1 - q[j] / 100.0) / d else r[j] / d end end end puts ans