Hoogle Search
Within LTS Haskell 24.31 (ghc-9.10.3)
Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.
sorted :: Ord a => MQuery a -> MQuery ahw-mquery HaskellWorks.Data.MQuery No documentation available.
sortBy :: forall a (n :: Nat) . (a -> a -> Ordering) -> NList n a -> NList n aindexed-containers Data.NList Non-overloaded version of sort.
sortBy (\x y -> compare (-x) (-y)) (mk6 1 4 2 8 5 7) === mk6 8 7 5 4 2 1
sortOn :: forall b a (n :: Nat) . Ord b => (a -> b) -> NList n a -> NList n aindexed-containers Data.NList Sort a list by applying a function to each element and comparing the results.
sortOn negate (mk6 1 4 2 8 5 7) === mk6 8 7 5 4 2 1
sortFreeTDNF :: (forall a' b' . () => f a' -> f b' -> Ordering) -> Free f a -> Free f ainvertible Control.Invertible.Monoidal.Free Equivalent to freeTDNF, but also sorts the terms within each Join clause to conform to the given ordering. The resulting Join trees will be right-linearized (Join x (Join y (Join z ...)) such that x <= y, y <= z, etc. THis performs a O(n^2) bubble sort on the already exponential TDNF.
sorted :: Ord a => [a] -> Boollist-predicate Data.List.Predicate O(n). Whether the elements are in sorted order.
>>> sorted [1, 2, 3, 3] True >>> sorted [1, 2, 3, 2] False >>> sorted [] True >>> sorted [1] True
sortedBy :: (a -> a -> Ordering) -> [a] -> Boollist-predicate Data.List.Predicate O(n). Like sorted, with a custom comparison test.
>>> sortedBy (comparing Down) [3, 2, 1] True >>> sortedBy (comparing Down) [3, 2, 1, 2] False
sortIndex :: (Ord t, Element t) => Vector t -> Vector Iqchas QC >>> m <- randn 4 10 >>> disp 2 m 4x10 -0.31 0.41 0.43 -0.19 -0.17 -0.23 -0.17 -1.04 -0.07 -1.24 0.26 0.19 0.14 0.83 -1.54 -0.09 0.37 -0.63 0.71 -0.50 -0.11 -0.10 -1.29 -1.40 -1.04 -0.89 -0.68 0.35 -1.46 1.86 1.04 -0.29 0.19 -0.75 -2.20 -0.01 1.06 0.11 -2.09 -1.58
>>> disp 2 $ m ?? (All, Pos $ sortIndex (m!1)) 4x10 -0.17 -1.04 -1.24 -0.23 0.43 0.41 -0.31 -0.17 -0.07 -0.19 -1.54 -0.63 -0.50 -0.09 0.14 0.19 0.26 0.37 0.71 0.83 -1.04 0.35 1.86 -0.89 -1.29 -0.10 -0.11 -0.68 -1.46 -1.40 -2.20 0.11 -1.58 -0.01 0.19 -0.29 1.04 1.06 -2.09 -0.75
sortVector :: (Ord t, Element t) => Vector t -> Vector tqchas QC No documentation available.
sortGraph :: Components -> PackageGraph -> IO ()rpmbuild-order Distribution.RPM.Build.Order output sorted packages from a PackageGraph arrange by Components
sortBy :: (a -> a -> Ordering) -> Vector a -> Vector arrb-vector Data.RRBVector Sort the vector in ascending order according to the specified comparison function. The sort is stable, meaning the order of equal elements is preserved.