import           Control.Applicative
import           Control.Monad
import           Data.List

main :: IO ()
main = do
  datasets <- takeWhile (/= "0") . lines <$> getContents
  putStr $ unlines $ map show $ process datasets []
    where
      process [] results = results
      process (num:nums:others) results = process others (results ++ [stdVar])
        where
          n = read num
          a = map (read::String->Double) $ words nums
          avg = (sum a) / n
          var = (sum $ map (\x -> (x- avg)^2) a) / n
          stdVar = sqrt var

