list replication haskell code example Example: list replication haskell f :: Int -> [Int] -> [Int] f n arr = concatMap (\num -> replicate n num) arr