Text processing/1: Difference between revisions
Content added Content deleted
(added Haskell) |
m (→{{header|Haskell}}: delete some ()) |
||
Line 554: | Line 554: | ||
-- output statistics |
-- output statistics |
||
putStrLn "\nSome lines:\n" |
putStrLn "\nSome lines:\n" |
||
mapM_ (\(d,((v,n),_)) -> printf lineFmt d n v |
mapM_ (\(d,((v,n),_)) -> printf lineFmt d n v (v/fromIntegral n)) $ take 4 $ drop 2200 dat |
||
(\(t,n) -> printf totalFmt n t (t/fromIntegral n)) $ fst summ |
(\(t,n) -> printf totalFmt n t (t/fromIntegral n)) $ fst summ |
||
mapM_ ((\(l, d1,d2) -> printf maxFmt l d1 d2) |
mapM_ ((\(l, d1,d2) -> printf maxFmt l d1 d2) |