class Array
	def avg
		inject(0.0){|r, i| r += i.to_i} / size
	end
	def variance
		a = avg
		inject(0.0){|r, i| r += (i.to_i - a) ** 2} / size
	end
	def standard_deviation
		Math.sqrt(variance)
	end
end

while true do 
	n = gets.to_i
	break if n == 0
	puts gets.split.map(&:to_i).standard_deviation
end