def gi gets.chomp.to_i end def gm gets.chomp.split.map(&:to_i) end def gc gets.chomp end def gs gets.chomp.split end N = gi ans = 0 for i in 0..N-1 x = gi ans += Math.sqrt(x) puts sprintf("%.20f", ans) end