aboutsummaryrefslogtreecommitdiff
path: root/docs/doc/search.html
diff options
context:
space:
mode:
Diffstat (limited to 'docs/doc/search.html')
-rw-r--r--docs/doc/search.html4
1 files changed, 2 insertions, 2 deletions
diff --git a/docs/doc/search.html b/docs/doc/search.html
index 7834a06d..28e0081d 100644
--- a/docs/doc/search.html
+++ b/docs/doc/search.html
@@ -146,7 +146,7 @@
<span class='String'>&quot;initial set&quot;</span> <span class='Paren'>(</span><span class='Function'>¬</span><span class='Modifier2'>∘</span><span class='Function'>∊/⊣</span><span class='Paren'>)</span> <span class='String'>&quot;difference&quot;</span> <span class='Comment'># Remove 𝕩
</span>"tal st"
</pre>
-<p>These are the APL functions Intersect (<code><span class='Value'>∩</span></code>) and Without (<code><span class='Value'>~</span></code>). Really, only <code><span class='Value'>𝕩</span></code> is treated like a set, while the ordering and multiplicity of elements of <code><span class='Value'>𝕨</span></code> are maintained. I think the explicit implementations show this well, since <code><span class='Value'>𝕩</span></code> is only used as the right argument to <code><span class='Function'>∊</span></code>, and prefer this clarity to the brevity of a single symbol.</p>
+<p>These functions appear in APL as Intersect (<code><span class='Value'>∩</span></code>) and Without (<code><span class='Value'>~</span></code>). Really, only <code><span class='Value'>𝕩</span></code> is treated like a set, while the ordering and multiplicity of elements of <code><span class='Value'>𝕨</span></code> are maintained. I think the explicit implementations show this well, since <code><span class='Value'>𝕩</span></code> is only used as the right argument to <code><span class='Function'>∊</span></code>, and prefer this clarity to the brevity of a single symbol.</p>
<h2 id="index-of"><a class="header" href="#index-of">Index of</a></h2>
<p>Index of (<code><span class='Function'>⊐</span></code>) returns the index of the first occurrence of each entry in <code><span class='Value'>𝕨</span></code>, or <code><span class='Function'>≠</span><span class='Value'>𝕨</span></code> if an entry doesn't appear in <code><span class='Value'>𝕨</span></code> at all.</p>
<a class="replLink" title="Open in the REPL" target="_blank" href="https://mlochbaum.github.io/BQN/try.html#code=Inplcm8i4oC/Im9uZSLigL8idHdvIuKAvyJ0aHJlZSIg4oqQICJvbmUi4oC/ImVpZ2h0IuKAvyJ0d28i">↗️</a><pre> <span class='String'>&quot;zero&quot;</span><span class='Ligature'>‿</span><span class='String'>&quot;one&quot;</span><span class='Ligature'>‿</span><span class='String'>&quot;two&quot;</span><span class='Ligature'>‿</span><span class='String'>&quot;three&quot;</span> <span class='Function'>⊐</span> <span class='String'>&quot;one&quot;</span><span class='Ligature'>‿</span><span class='String'>&quot;eight&quot;</span><span class='Ligature'>‿</span><span class='String'>&quot;two&quot;</span>
@@ -178,7 +178,7 @@
<span class='String'>&quot;aabbcc&quot;</span> <span class='Paren'>((</span><span class='Function'>⊒</span><span class='Modifier'>˜</span><span class='Function'>=≠</span><span class='Modifier2'>∘</span><span class='Function'>⊢</span><span class='Paren'>)</span><span class='Function'>/⊣</span><span class='Paren'>)</span> <span class='String'>&quot;baa&quot;</span> <span class='Comment'># Multiset difference
</span>"bcc"
</pre>
-<p>This primitive gives an interesting way to implement the <a href="order.html#ordinals">ordinals</a> pattern that might be easier to understand than the APL classic <code><span class='Function'>⍋⍋</span></code> (it's probably a little slower though). The idea is to use the sorted array as the left argument to <code><span class='Function'>⊒</span></code>. Now the index returned for each cell is just where it ended up in that sorted order. If we used ordinary Index of then equal cells would share the smallest index; Progressive Index of means ties are broken in favor of earlier cells.</p>
+<p>This primitive gives an interesting way to implement the <a href="order.html#ordinals">ordinals</a> pattern that might be easier to understand than the classic <code><span class='Function'>⍋⍋</span></code> (it's probably a little slower though). The idea is to use the sorted array as the left argument to <code><span class='Function'>⊒</span></code>. Now the index returned for each cell is just where it ended up in that sorted order. If we used ordinary Index of then equal cells would share the smallest index; Progressive Index of means ties are broken in favor of earlier cells.</p>
<a class="replLink" title="Open in the REPL" target="_blank" href="https://mlochbaum.github.io/BQN/try.html#code=4o2L4oiY4o2LICJhZGViY2VkYmEiCgriiKfiirjiipIgImFkZWJjZWRiYSIKCuKIp+KKuOKKkCAiYWRlYmNlZGJhIiAgIyBUaWVzIGluY2x1ZGVk">↗️</a><pre> <span class='Function'>⍋</span><span class='Modifier2'>∘</span><span class='Function'>⍋</span> <span class='String'>&quot;adebcedba&quot;</span>
⟨ 0 5 7 2 4 8 6 3 1 ⟩