mmsyn5-0.1.3.0: Various additional operations on lists

Copyright(c) OleksandrZhabenko 2019
LicenseMIT
Maintainerolexandr543@yahoo.com
Safe HaskellSafe
LanguageHaskell2010

Data.List.Nth

Contents

Description

Various additional operations on lists.

Synopsis

Operations on lists to take a part of a list

takeNth :: Int -> (a -> Bool) -> [a] -> [a] Source #

Function that takes a list containing elements consequently up to n occurencies of p a = True in map p [a]

takeWithFirst :: (a -> Bool) -> [a] -> [a] Source #

Function to take elements of the list till the first occurence of p a = True in 'map p [a]' including the element which results in the first occurance

dropNth :: Int -> (a -> Bool) -> [a] -> [a] Source #

Function that drops a list containing elements consequently up to n occurencies of p a = True in map p [a]

dropWithFirst :: (a -> Bool) -> [a] -> [a] Source #

Function to take elements of the list after the first occurence of p a = True in map p [a] excluding the element which results in the first occurance

Operation to apply a function that creates an inner list to an element of the outer list

bGroups :: (a -> Bool) -> (a -> [a]) -> [a] -> [a] Source #

Function that applies additional function f to a if p a = True