Commit 479cd1f4 authored by Vaibhav Sagar's avatar Vaibhav Sagar

notebooks/IHaskell.ipynb: update

parent 376d108d
......@@ -1882,13 +1882,24 @@
"</pre>\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/Cabal/docs/Distribution-Compat-Prelude-Internal.html#v:zip'><s0>zip</s0></a> &#x2237; () &#x21D2; [a] &#x2192; [b] &#x2192; [(a, b)]</span><div class='hoogle-doc'><a>zip</a> takes two lists and returns a list of corresponding pairs.\n",
"\n",
"<pre>\n",
"zip [1, 2] ['a', 'b'] = [(1, 'a'), (2, 'b')]\n",
"</pre>\n",
"\n",
"If one input list is short, excess elements of the longer list are\n",
"discarded.\n",
"discarded:\n",
"\n",
"<pre>\n",
"zip [1] ['a', 'b'] = [(1, 'a')]\n",
"zip [1, 2] ['a'] = [(1, 'a')]\n",
"</pre>\n",
"\n",
"<a>zip</a> is right-lazy:\n",
"\n",
"<pre>\n",
"zip [] _|_ = []\n",
"zip _|_ [] = _|_\n",
"</pre>\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/safe/docs/Safe-Exact.html#v:zipExact'><s0>zipExact</s0></a> &#x2237; Partial &#x21D2; [a] &#x2192; [b] &#x2192; [(a, b)]</span><div class='hoogle-doc'><pre>\n",
......@@ -1938,25 +1949,48 @@
"</pre>\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/rio/docs/RIO.html#v:zip'><s0>zip</s0></a> &#x2237; () &#x21D2; [a] &#x2192; [b] &#x2192; [(a, b)]</span><div class='hoogle-doc'><a>zip</a> takes two lists and returns a list of corresponding pairs.\n",
"\n",
"<pre>\n",
"zip [1, 2] ['a', 'b'] = [(1, 'a'), (2, 'b')]\n",
"</pre>\n",
"\n",
"If one input list is short, excess elements of the longer list are\n",
"discarded.\n",
"discarded:\n",
"\n",
"<pre>\n",
"zip [1] ['a', 'b'] = [(1, 'a')]\n",
"zip [1, 2] ['a'] = [(1, 'a')]\n",
"</pre>\n",
"\n",
"<a>zip</a> is right-lazy:\n",
"\n",
"<pre>\n",
"zip [] _|_ = []\n",
"zip _|_ [] = _|_\n",
"</pre>\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/rio/docs/RIO-List.html#v:zip'><s0>zip</s0></a> &#x2237; () &#x21D2; [a] &#x2192; [b] &#x2192; [(a, b)]</span><div class='hoogle-doc'><a>zip</a> takes two lists and returns a list of corresponding pairs.\n",
"\n",
"<pre>\n",
"zip [1, 2] ['a', 'b'] = [(1, 'a'), (2, 'b')]\n",
"</pre>\n",
"\n",
"If one input list is short, excess elements of the longer list are\n",
"discarded.\n",
"discarded:\n",
"\n",
"<pre>\n",
"zip [1] ['a', 'b'] = [(1, 'a')]\n",
"zip [1, 2] ['a'] = [(1, 'a')]\n",
"</pre>\n",
"\n",
"<a>zip</a> is right-lazy:\n",
"\n",
"<pre>\n",
"zip [] _|_ = []\n",
"zip _|_ [] = _|_\n",
"</pre>\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/fay-base/docs/Prelude.html#v:zip'><s0>zip</s0></a> &#x2237; [a] &#x2192; [b] &#x2192; [(a, b)]</span><div class='hoogle-doc'></div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/rebase/docs/Rebase-Prelude.html#v:zip'><s0>zip</s0></a> &#x2237; () &#x21D2; [a] &#x2192; [b] &#x2192; [(a, b)]</span><div class='hoogle-doc'><a>zip</a> takes two lists and returns a list of corresponding pairs.\n",
"If one input list is short, excess elements of the longer list are\n",
"discarded.\n",
......@@ -1967,7 +2001,6 @@
"zip [] _|_ = []\n",
"</pre>\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/fay-base/docs/Prelude.html#v:zip'><s0>zip</s0></a> &#x2237; [a] &#x2192; [b] &#x2192; [(a, b)]</span><div class='hoogle-doc'></div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/universe-base/docs/Data-Universe-Helpers.html#v:-43--42--43-'>(<s0>+*+</s0>)</a> &#x2237; [a] &#x2192; [b] &#x2192; [(a, b)]</span><div class='hoogle-doc'>Slightly unfair 2-way Cartesian product: given two (possibly infinite)\n",
"lists, produce a single list such that whenever <tt>v</tt> and\n",
"<tt>w</tt> have finite indices in the input lists, <tt>(v,w)</tt> has\n",
......@@ -2139,13 +2172,24 @@
"</pre>\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/hledger-web/docs/Hledger-Web-Import.html#v:zip'><s0>zip</s0></a> &#x2237; () &#x21D2; [a] &#x2192; [b] &#x2192; [(a, b)]</span><div class='hoogle-doc'><a>zip</a> takes two lists and returns a list of corresponding pairs.\n",
"\n",
"<pre>\n",
"zip [1, 2] ['a', 'b'] = [(1, 'a'), (2, 'b')]\n",
"</pre>\n",
"\n",
"If one input list is short, excess elements of the longer list are\n",
"discarded.\n",
"discarded:\n",
"\n",
"<pre>\n",
"zip [1] ['a', 'b'] = [(1, 'a')]\n",
"zip [1, 2] ['a'] = [(1, 'a')]\n",
"</pre>\n",
"\n",
"<a>zip</a> is right-lazy:\n",
"\n",
"<pre>\n",
"zip [] _|_ = []\n",
"zip _|_ [] = _|_\n",
"</pre>\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/ghc/docs/Util.html#v:zipLazy'><s0>zipLazy</s0></a> &#x2237; [a] &#x2192; [b] &#x2192; [(a, b)]</span><div class='hoogle-doc'><a>zipLazy</a> is a kind of <a>zip</a> that is lazy in the second list\n",
......@@ -2158,15 +2202,10 @@
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/invertible/docs/Control-Invertible-Monoidal.html#v:pairADefault'><s0>pairADefault</s0></a> &#x2237; Applicative f &#x21D2; f a &#x2192; f b &#x2192; f (a, b)</span><div class='hoogle-doc'>Default '&gt;*&lt; implementation for non-invertible\n",
"<a>Applicative</a>s.\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/vector/docs/Data-Vector-Generic.html#v:zip'><s0>zip</s0></a> &#x2237; (Vector v a, Vector v b, Vector v (a, b)) &#x21D2; v a &#x2192; v b &#x2192; v (a, b)</span><div class='hoogle-doc'><i>O(min(m,n))</i> Zip two vectors\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/statistics/docs/Statistics-Sample.html#v:pair'><s0>pair</s0></a> &#x2237; (Vector v a, Vector v b, Vector v (a, b)) &#x21D2; v a &#x2192; v b &#x2192; v (a, b)</span><div class='hoogle-doc'>Pair two samples. It's like <a>zip</a> but requires that both samples\n",
"have equal size.\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/rio/docs/RIO-Vector.html#v:zip'><s0>zip</s0></a> &#x2237; (Vector v a, Vector v b, Vector v (a, b)) &#x21D2; v a &#x2192; v b &#x2192; v (a, b)</span><div class='hoogle-doc'><i>O(min(m,n))</i> Zip two vectors\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/unliftio/docs/UnliftIO-Async.html#v:concurrently'><s0>concurrently</s0></a> &#x2237; MonadUnliftIO m &#x21D2; m a &#x2192; m b &#x2192; m (a, b)</span><div class='hoogle-doc'>Unlifted <a>concurrently</a>.\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/unliftio/docs/UnliftIO-Internals-Async.html#v:concurrently'><s0>concurrently</s0></a> &#x2237; MonadUnliftIO m &#x21D2; m a &#x2192; m b &#x2192; m (a, b)</span><div class='hoogle-doc'>Unlifted <a>concurrently</a>.\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/stack/docs/Stack-Prelude.html#v:concurrently'><s0>concurrently</s0></a> &#x2237; MonadUnliftIO m &#x21D2; m a &#x2192; m b &#x2192; m (a, b)</span><div class='hoogle-doc'>Unlifted <a>concurrently</a>.\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/yesod-websockets/docs/Yesod-WebSockets.html#v:concurrently'><s0>concurrently</s0></a> &#x2237; MonadUnliftIO m &#x21D2; m a &#x2192; m b &#x2192; m (a, b)</span><div class='hoogle-doc'>Unlifted <a>concurrently</a>.\n",
......@@ -2192,6 +2231,7 @@
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/EdisonCore/docs/Data-Edison-Seq-Defaults.html#v:zipUsingLview'><s0>zipUsingLview</s0></a> &#x2237; Sequence s &#x21D2; s a &#x2192; s b &#x2192; s (a, b)</span><div class='hoogle-doc'></div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/EdisonCore/docs/Data-Edison-Seq-Defaults.html#v:zipUsingLists'><s0>zipUsingLists</s0></a> &#x2237; Sequence s &#x21D2; s a &#x2192; s b &#x2192; s (a, b)</span><div class='hoogle-doc'></div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/adjunctions/docs/Data-Functor-Rep.html#v:mzipRep'><s0>mzipRep</s0></a> &#x2237; Representable f &#x21D2; f a &#x2192; f b &#x2192; f (a, b)</span><div class='hoogle-doc'></div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/concurrency/docs/Control-Concurrent-Classy-Async.html#v:concurrently'><s0>concurrently</s0></a> &#x2237; MonadConc m &#x21D2; m a &#x2192; m b &#x2192; m (a, b)</span><div class='hoogle-doc'>Run two <tt>MonadConc</tt> actions concurrently, and return both\n",
"results. If either action throws an exception at any time, then the\n",
"other action is <a>cancel</a>led, and the exception is re-thrown by\n",
......@@ -2204,35 +2244,6 @@
"waitBoth a b\n",
"</pre>\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/adjunctions/docs/Data-Functor-Rep.html#v:mzipRep'><s0>mzipRep</s0></a> &#x2237; Representable f &#x21D2; f a &#x2192; f b &#x2192; f (a, b)</span><div class='hoogle-doc'></div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/algebraic-graphs/docs/Algebra-Graph-HigherKinded-Class.html#v:box'><s0>box</s0></a> &#x2237; Graph g &#x21D2; g a &#x2192; g b &#x2192; g (a, b)</span><div class='hoogle-doc'>Compute the <i>Cartesian product</i> of graphs. Complexity: <i>O(s1 *\n",
"s2)</i> time, memory and size, where <i>s1</i> and <i>s2</i> are the\n",
"sizes of the given graphs.\n",
"\n",
"<pre>\n",
"box (<a>path</a> [0,1]) (<a>path</a> \"ab\") == <a>edges</a> [ ((0,'a'), (0,'b'))\n",
", ((0,'a'), (1,'a'))\n",
", ((0,'b'), (1,'b'))\n",
", ((1,'a'), (1,'b')) ]\n",
"</pre>\n",
"\n",
"Up to an isomorphism between the resulting vertex types, this\n",
"operation is <i>commutative</i>, <i>associative</i>,\n",
"<i>distributes</i> over <a>overlay</a>, has singleton graphs as\n",
"<i>identities</i> and <a>empty</a> as the <i>annihilating zero</i>.\n",
"Below <tt>~~</tt> stands for the equality up to an isomorphism, e.g.\n",
"<tt>(x, ()) ~~ x</tt>.\n",
"\n",
"<pre>\n",
"box x y ~~ box y x\n",
"box x (box y z) ~~ box (box x y) z\n",
"box x (<a>overlay</a> y z) == <a>overlay</a> (box x y) (box x z)\n",
"box x (<a>vertex</a> ()) ~~ x\n",
"box x <a>empty</a> ~~ <a>empty</a>\n",
"<a>vertexCount</a> (box x y) == <a>vertexCount</a> x * <a>vertexCount</a> y\n",
"<tt>edgeCount</tt> (box x y) &lt;= <a>vertexCount</a> x * <tt>edgeCount</tt> y + <tt>edgeCount</tt> x * <a>vertexCount</a> y\n",
"</pre>\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/contravariant/docs/Data-Functor-Contravariant-Divisible.html#v:divided'><s0>divided</s0></a> &#x2237; Divisible f &#x21D2; f a &#x2192; f b &#x2192; f (a, b)</span><div class='hoogle-doc'><pre>\n",
"<a>divided</a> = <a>divide</a> <a>id</a>\n",
"</pre>\n",
......@@ -2308,6 +2319,13 @@
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/rebase/docs/Rebase-Prelude.html#v:contrazip2'><s0>contrazip2</s0></a> &#x2237; Divisible f &#x21D2; f a1 &#x2192; f a2 &#x2192; f (a1, a2)</span><div class='hoogle-doc'></div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/contravariant-extras/docs/Contravariant-Extras-Contrazip.html#v:contrazip2'><s0>contrazip2</s0></a> &#x2237; &#x2200; f a1 a2 . Divisible f &#x21D2; f a1 &#x2192; f a2 &#x2192; f (a1, a2)</span><div class='hoogle-doc'></div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/vector/docs/Data-Vector-Generic.html#v:zip'><s0>zip</s0></a> &#x2237; (Vector v a, Vector v b, Vector v (a, b)) &#x21D2; v a &#x2192; v b &#x2192; v (a, b)</span><div class='hoogle-doc'><i>O(min(m,n))</i> Zip two vectors\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/statistics/docs/Statistics-Sample.html#v:pair'><s0>pair</s0></a> &#x2237; (Vector v a, Vector v b, Vector v (a, b)) &#x21D2; v a &#x2192; v b &#x2192; v (a, b)</span><div class='hoogle-doc'>Pair two samples. It's like <a>zip</a> but requires that both samples\n",
"have equal size.\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/rio/docs/RIO-Vector.html#v:zip'><s0>zip</s0></a> &#x2237; (Vector v a, Vector v b, Vector v (a, b)) &#x21D2; v a &#x2192; v b &#x2192; v (a, b)</span><div class='hoogle-doc'><i>O(min(m,n))</i> Zip two vectors\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/size-based/docs/Control-Sized.html#v:pair'><s0>pair</s0></a> &#x2237; Sized f &#x21D2; f a &#x2192; f b &#x2192; f (a, b)</span><div class='hoogle-doc'>Default: <tt>pair a b = (,) <a>$</a> a <a>*</a> b</tt>.\n",
"</div>\n",
"<span class='hoogle-name'><a target='_blank' href='https://hackage.haskell.org/package/bytestring/docs/Data-ByteString-Builder-Prim.html#v:-62--42--60-'>(<s0>>*<</s0>)</a> &#x2237; Monoidal f &#x21D2; f a &#x2192; f b &#x2192; f (a, b)</span><div class='hoogle-doc'>A pairing/concatenation operator for builder primitives, both bounded\n",
......@@ -2362,7 +2380,7 @@
"mesh xs [] == <a>empty</a>\n",
"mesh [] ys == <a>empty</a>\n",
"mesh [x] [y] == <a>vertex</a> (x, y)\n",
"mesh xs ys == <a>box</a> (<a>path</a> xs) (<a>path</a> ys)\n",
"mesh xs ys == <tt>box</tt> (<a>path</a> xs) (<a>path</a> ys)\n",
"mesh [1..3] \"ab\" == <a>edges</a> [ ((1,'a'),(1,'b')), ((1,'a'),(2,'a')), ((1,'b'),(2,'b')), ((2,'a'),(2,'b'))\n",
", ((2,'a'),(3,'a')), ((2,'b'),(3,'b')), ((3,'a'),(3,'b')) ]\n",
"</pre>\n",
......@@ -2375,7 +2393,7 @@
"torus xs [] == <a>empty</a>\n",
"torus [] ys == <a>empty</a>\n",
"torus [x] [y] == <a>edge</a> (x,y) (x,y)\n",
"torus xs ys == <a>box</a> (<a>circuit</a> xs) (<a>circuit</a> ys)\n",
"torus xs ys == <tt>box</tt> (<a>circuit</a> xs) (<a>circuit</a> ys)\n",
"torus [1,2] \"ab\" == <a>edges</a> [ ((1,'a'),(1,'b')), ((1,'a'),(2,'a')), ((1,'b'),(1,'a')), ((1,'b'),(2,'b'))\n",
", ((2,'a'),(1,'a')), ((2,'a'),(2,'b')), ((2,'b'),(1,'b')), ((2,'b'),(2,'a')) ]\n",
"</pre>\n",
......@@ -2501,13 +2519,24 @@
"<s0>zip</s0> :: () => [a] -> [b] -> [(a, b)]\n",
"URL: https://hackage.haskell.org/package/Cabal/docs/Distribution-Compat-Prelude-Internal.html#v:zip\n",
"<a>zip</a> takes two lists and returns a list of corresponding pairs.\n",
"\n",
"<pre>\n",
"zip [1, 2] ['a', 'b'] = [(1, 'a'), (2, 'b')]\n",
"</pre>\n",
"\n",
"If one input list is short, excess elements of the longer list are\n",
"discarded.\n",
"discarded:\n",
"\n",
"<pre>\n",
"zip [1] ['a', 'b'] = [(1, 'a')]\n",
"zip [1, 2] ['a'] = [(1, 'a')]\n",
"</pre>\n",
"\n",
"<a>zip</a> is right-lazy:\n",
"\n",
"<pre>\n",
"zip [] _|_ = []\n",
"zip _|_ [] = _|_\n",
"</pre>\n",
"\n",
"<s0>zipExact</s0> :: Partial => [a] -> [b] -> [(a, b)]\n",
......@@ -2569,27 +2598,52 @@
"<s0>zip</s0> :: () => [a] -> [b] -> [(a, b)]\n",
"URL: https://hackage.haskell.org/package/rio/docs/RIO.html#v:zip\n",
"<a>zip</a> takes two lists and returns a list of corresponding pairs.\n",
"\n",
"<pre>\n",
"zip [1, 2] ['a', 'b'] = [(1, 'a'), (2, 'b')]\n",
"</pre>\n",
"\n",
"If one input list is short, excess elements of the longer list are\n",
"discarded.\n",
"discarded:\n",
"\n",
"<pre>\n",
"zip [1] ['a', 'b'] = [(1, 'a')]\n",
"zip [1, 2] ['a'] = [(1, 'a')]\n",
"</pre>\n",
"\n",
"<a>zip</a> is right-lazy:\n",
"\n",
"<pre>\n",
"zip [] _|_ = []\n",
"zip _|_ [] = _|_\n",
"</pre>\n",
"\n",
"<s0>zip</s0> :: () => [a] -> [b] -> [(a, b)]\n",
"URL: https://hackage.haskell.org/package/rio/docs/RIO-List.html#v:zip\n",
"<a>zip</a> takes two lists and returns a list of corresponding pairs.\n",
"\n",
"<pre>\n",
"zip [1, 2] ['a', 'b'] = [(1, 'a'), (2, 'b')]\n",
"</pre>\n",
"\n",
"If one input list is short, excess elements of the longer list are\n",
"discarded.\n",
"discarded:\n",
"\n",
"<pre>\n",
"zip [1] ['a', 'b'] = [(1, 'a')]\n",
"zip [1, 2] ['a'] = [(1, 'a')]\n",
"</pre>\n",
"\n",
"<a>zip</a> is right-lazy:\n",
"\n",
"<pre>\n",
"zip [] _|_ = []\n",
"zip _|_ [] = _|_\n",
"</pre>\n",
"\n",
"<s0>zip</s0> :: [a] -> [b] -> [(a, b)]\n",
"URL: https://hackage.haskell.org/package/fay-base/docs/Prelude.html#v:zip\n",
"\n",
"<s0>zip</s0> :: () => [a] -> [b] -> [(a, b)]\n",
"URL: https://hackage.haskell.org/package/rebase/docs/Rebase-Prelude.html#v:zip\n",
"<a>zip</a> takes two lists and returns a list of corresponding pairs.\n",
......@@ -2602,9 +2656,6 @@
"zip [] _|_ = []\n",
"</pre>\n",
"\n",
"<s0>zip</s0> :: [a] -> [b] -> [(a, b)]\n",
"URL: https://hackage.haskell.org/package/fay-base/docs/Prelude.html#v:zip\n",
"\n",
"(<s0>+*+</s0>) :: [a] -> [b] -> [(a, b)]\n",
"URL: https://hackage.haskell.org/package/universe-base/docs/Data-Universe-Helpers.html#v:-43--42--43-\n",
"Slightly unfair 2-way Cartesian product: given two (possibly infinite)\n",
......@@ -2808,13 +2859,24 @@
"<s0>zip</s0> :: () => [a] -> [b] -> [(a, b)]\n",
"URL: https://hackage.haskell.org/package/hledger-web/docs/Hledger-Web-Import.html#v:zip\n",
"<a>zip</a> takes two lists and returns a list of corresponding pairs.\n",
"\n",
"<pre>\n",
"zip [1, 2] ['a', 'b'] = [(1, 'a'), (2, 'b')]\n",
"</pre>\n",
"\n",
"If one input list is short, excess elements of the longer list are\n",
"discarded.\n",
"discarded:\n",
"\n",
"<pre>\n",
"zip [1] ['a', 'b'] = [(1, 'a')]\n",
"zip [1, 2] ['a'] = [(1, 'a')]\n",
"</pre>\n",
"\n",
"<a>zip</a> is right-lazy:\n",
"\n",
"<pre>\n",
"zip [] _|_ = []\n",
"zip _|_ [] = _|_\n",
"</pre>\n",
"\n",
"<s0>zipLazy</s0> :: [a] -> [b] -> [(a, b)]\n",
......@@ -2835,24 +2897,15 @@
"Default '&gt;*&lt; implementation for non-invertible\n",
"<a>Applicative</a>s.\n",
"\n",
"<s0>zip</s0> :: (Vector v a, Vector v b, Vector v (a, b)) => v a -> v b -> v (a, b)\n",
"URL: https://hackage.haskell.org/package/vector/docs/Data-Vector-Generic.html#v:zip\n",
"<i>O(min(m,n))</i> Zip two vectors\n",
"\n",
"<s0>pair</s0> :: (Vector v a, Vector v b, Vector v (a, b)) => v a -> v b -> v (a, b)\n",
"URL: https://hackage.haskell.org/package/statistics/docs/Statistics-Sample.html#v:pair\n",
"Pair two samples. It's like <a>zip</a> but requires that both samples\n",
"have equal size.\n",
"\n",
"<s0>zip</s0> :: (Vector v a, Vector v b, Vector v (a, b)) => v a -> v b -> v (a, b)\n",
"URL: https://hackage.haskell.org/package/rio/docs/RIO-Vector.html#v:zip\n",
"<i>O(min(m,n))</i> Zip two vectors\n",
"\n",
"<s0>concurrently</s0> :: MonadUnliftIO m => m a -> m b -> m (a, b)\n",
"URL: https://hackage.haskell.org/package/unliftio/docs/UnliftIO-Async.html#v:concurrently\n",
"Unlifted <a>concurrently</a>.\n",
"\n",
"<s0>concurrently</s0> :: MonadUnliftIO m => m a -> m b -> m (a, b)\n",
"URL: https://hackage.haskell.org/package/unliftio/docs/UnliftIO-Internals-Async.html#v:concurrently\n",
"Unlifted <a>concurrently</a>.\n",
"\n",
"<s0>concurrently</s0> :: MonadUnliftIO m => m a -> m b -> m (a, b)\n",
"URL: https://hackage.haskell.org/package/stack/docs/Stack-Prelude.html#v:concurrently\n",
"Unlifted <a>concurrently</a>.\n",
"\n",
......@@ -2887,6 +2940,9 @@
"<s0>zipUsingLists</s0> :: Sequence s => s a -> s b -> s (a, b)\n",
"URL: https://hackage.haskell.org/package/EdisonCore/docs/Data-Edison-Seq-Defaults.html#v:zipUsingLists\n",
"\n",
"<s0>mzipRep</s0> :: Representable f => f a -> f b -> f (a, b)\n",
"URL: https://hackage.haskell.org/package/adjunctions/docs/Data-Functor-Rep.html#v:mzipRep\n",
"\n",
"<s0>concurrently</s0> :: MonadConc m => m a -> m b -> m (a, b)\n",
"URL: https://hackage.haskell.org/package/concurrency/docs/Control-Concurrent-Classy-Async.html#v:concurrently\n",
"Run two <tt>MonadConc</tt> actions concurrently, and return both\n",
......@@ -2901,39 +2957,6 @@
"waitBoth a b\n",
"</pre>\n",
"\n",
"<s0>mzipRep</s0> :: Representable f => f a -> f b -> f (a, b)\n",
"URL: https://hackage.haskell.org/package/adjunctions/docs/Data-Functor-Rep.html#v:mzipRep\n",
"\n",
"<s0>box</s0> :: Graph g => g a -> g b -> g (a, b)\n",
"URL: https://hackage.haskell.org/package/algebraic-graphs/docs/Algebra-Graph-HigherKinded-Class.html#v:box\n",
"Compute the <i>Cartesian product</i> of graphs. Complexity: <i>O(s1 *\n",
"s2)</i> time, memory and size, where <i>s1</i> and <i>s2</i> are the\n",
"sizes of the given graphs.\n",
"\n",
"<pre>\n",
"box (<a>path</a> [0,1]) (<a>path</a> \"ab\") == <a>edges</a> [ ((0,'a'), (0,'b'))\n",
", ((0,'a'), (1,'a'))\n",
", ((0,'b'), (1,'b'))\n",
", ((1,'a'), (1,'b')) ]\n",
"</pre>\n",
"\n",
"Up to an isomorphism between the resulting vertex types, this\n",
"operation is <i>commutative</i>, <i>associative</i>,\n",
"<i>distributes</i> over <a>overlay</a>, has singleton graphs as\n",
"<i>identities</i> and <a>empty</a> as the <i>annihilating zero</i>.\n",
"Below <tt>~~</tt> stands for the equality up to an isomorphism, e.g.\n",
"<tt>(x, ()) ~~ x</tt>.\n",
"\n",
"<pre>\n",
"box x y ~~ box y x\n",
"box x (box y z) ~~ box (box x y) z\n",
"box x (<a>overlay</a> y z) == <a>overlay</a> (box x y) (box x z)\n",
"box x (<a>vertex</a> ()) ~~ x\n",
"box x <a>empty</a> ~~ <a>empty</a>\n",
"<a>vertexCount</a> (box x y) == <a>vertexCount</a> x * <a>vertexCount</a> y\n",
"<tt>edgeCount</tt> (box x y) &lt;= <a>vertexCount</a> x * <tt>edgeCount</tt> y + <tt>edgeCount</tt> x * <a>vertexCount</a> y\n",
"</pre>\n",
"\n",
"<s0>divided</s0> :: Divisible f => f a -> f b -> f (a, b)\n",
"URL: https://hackage.haskell.org/package/contravariant/docs/Data-Functor-Contravariant-Divisible.html#v:divided\n",
"<pre>\n",
......@@ -3023,6 +3046,19 @@
"<s0>contrazip2</s0> :: forall f a1 a2 . Divisible f => f a1 -> f a2 -> f (a1, a2)\n",
"URL: https://hackage.haskell.org/package/contravariant-extras/docs/Contravariant-Extras-Contrazip.html#v:contrazip2\n",
"\n",
"<s0>zip</s0> :: (Vector v a, Vector v b, Vector v (a, b)) => v a -> v b -> v (a, b)\n",
"URL: https://hackage.haskell.org/package/vector/docs/Data-Vector-Generic.html#v:zip\n",
"<i>O(min(m,n))</i> Zip two vectors\n",
"\n",
"<s0>pair</s0> :: (Vector v a, Vector v b, Vector v (a, b)) => v a -> v b -> v (a, b)\n",
"URL: https://hackage.haskell.org/package/statistics/docs/Statistics-Sample.html#v:pair\n",
"Pair two samples. It's like <a>zip</a> but requires that both samples\n",
"have equal size.\n",
"\n",
"<s0>zip</s0> :: (Vector v a, Vector v b, Vector v (a, b)) => v a -> v b -> v (a, b)\n",
"URL: https://hackage.haskell.org/package/rio/docs/RIO-Vector.html#v:zip\n",
"<i>O(min(m,n))</i> Zip two vectors\n",
"\n",
"<s0>pair</s0> :: Sized f => f a -> f b -> f (a, b)\n",
"URL: https://hackage.haskell.org/package/size-based/docs/Control-Sized.html#v:pair\n",
"Default: <tt>pair a b = (,) <a>$</a> a <a>*</a> b</tt>.\n",
......@@ -3117,7 +3153,7 @@
"mesh xs [] == <a>empty</a>\n",
"mesh [] ys == <a>empty</a>\n",
"mesh [x] [y] == <a>vertex</a> (x, y)\n",
"mesh xs ys == <a>box</a> (<a>path</a> xs) (<a>path</a> ys)\n",
"mesh xs ys == <tt>box</tt> (<a>path</a> xs) (<a>path</a> ys)\n",
"mesh [1..3] \"ab\" == <a>edges</a> [ ((1,'a'),(1,'b')), ((1,'a'),(2,'a')), ((1,'b'),(2,'b')), ((2,'a'),(2,'b'))\n",
", ((2,'a'),(3,'a')), ((2,'b'),(3,'b')), ((3,'a'),(3,'b')) ]\n",
"</pre>\n",
......@@ -3132,7 +3168,7 @@
"torus xs [] == <a>empty</a>\n",
"torus [] ys == <a>empty</a>\n",
"torus [x] [y] == <a>edge</a> (x,y) (x,y)\n",
"torus xs ys == <a>box</a> (<a>circuit</a> xs) (<a>circuit</a> ys)\n",
"torus xs ys == <tt>box</tt> (<a>circuit</a> xs) (<a>circuit</a> ys)\n",
"torus [1,2] \"ab\" == <a>edges</a> [ ((1,'a'),(1,'b')), ((1,'a'),(2,'a')), ((1,'b'),(1,'a')), ((1,'b'),(2,'b'))\n",
", ((2,'a'),(1,'a')), ((2,'a'),(2,'b')), ((2,'b'),(1,'b')), ((2,'b'),(2,'a')) ]\n",
"</pre>\n",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment