import Control.Applicative

import Data.List
    (intersperse)
    
import Text.Printf
    (printf)
    
type Data = [Double]

type Set = (Int, Data)

type Problem = [Set]

type Result = [Double]

calcDeviation :: Set -> Double

calcDeviation (n, list)
    = sqrt a where
        m = sum list / fromIntegral n
        s = sum $ map (\x -> (x - m) ** 2) list
        a = s / fromIntegral n

solve :: Problem -> Result

solve problem
    = map calcDeviation problem

output :: Result -> String

output result
    = concat $ intersperse "\n" $ map (printf "%.6f") result
    
input :: IO Problem

input
    = inputProblem []
    
inputProblem :: Problem -> IO Problem

inputProblem problem
    = do
        n <- read <$> getLine
        if n == 0
            then return problem
            else do
                list <- map read.words <$> getLine
                inputProblem $ problem ++ [(n, list)]

main :: IO ()

main
    = putStr.output =<< solve <$> input