aboutsummaryrefslogtreecommitdiff
path: root/docs/doc/based.html
diff options
context:
space:
mode:
authorMarshall Lochbaum <mwlochbaum@gmail.com>2022-06-26 21:00:25 -0400
committerMarshall Lochbaum <mwlochbaum@gmail.com>2022-06-26 21:00:25 -0400
commitb6185d5029e2adcc721c0cc2097f591d9a09f135 (patch)
treebf777353ed2a9b28d8b1577c5f36b68605240375 /docs/doc/based.html
parentc618ade174cc2b4e428457751ad8dd01130c2239 (diff)
I am in editing stepped in so far that, should I wade no more, returning were as tedious as go o'er.
Diffstat (limited to 'docs/doc/based.html')
-rw-r--r--docs/doc/based.html2
1 files changed, 1 insertions, 1 deletions
diff --git a/docs/doc/based.html b/docs/doc/based.html
index f03adf29..4aa345f9 100644
--- a/docs/doc/based.html
+++ b/docs/doc/based.html
@@ -11,7 +11,7 @@
<p>If you're an array programmer then I have bad news for you. My thesis here is that APL took a wrong turn around 1981 when it extrapolated the excellent, but limited, flat array model of APL\360 to the ill-founded nested array model and the rigorous but clumsy boxed array model. Make that two wrong turns, I guess. Simultaneously. Anyway, if you've been brought up in either of these array models, then the best thing to do when starting BQN is to throw out your existing ideas about array depth and nesting (but don't worry too much: the fundamental concept of an array as a rectangular collection of data still holds!). If you'd like to ponder the relationship of BQN to APL later, that's great, but trying to initially understand BQN in terms of APL or J will just cause confusion.</p>
<h2 id="starting-from-atoms"><a class="header" href="#starting-from-atoms">Starting from atoms</a></h2>
<p>APL tends to define its data by starting with the array and then looking downwards in depth at what it contains. The based array model, as the name suggests, starts at the foundations, which in BQN are called &quot;atoms&quot;. There are six <a href="types.html">types</a> of atom, which together with the array type give the seven types a value can have in BQN. Based means being yourself, and an atom's <em>not</em> an array.</p>
-<p>An atom has <a href="depth.html">depth</a> 0, and doesn't inherently have a shape. However, primitives that expect an array promote atoms by <a href="enclose.html">enclosing</a> them to get a rank-0, or <em>unit</em>, array that contains the atom (any value can be enclosed in this way, giving a unit array with higher depth, but it only happens automatically for atoms). <a href="shape.html">Rank and shape</a> both do this, so an atom can be considered to have the same dimensions as a unit array: rank 0 and shape <code><span class='Bracket'>⟨⟩</span></code>. An atom is also considered a kind of unit, but it's not a unit array.</p>
+<p>An atom has <a href="depth.html">depth</a> 0, and doesn't inherently have a shape. However, primitives that expect an array will promote an atom by <a href="enclose.html">enclosing</a> to get a rank-0, or <em>unit</em>, array that contains it (any value can be enclosed in this way, giving a unit array with higher depth, but it only happens automatically for atoms). <a href="shape.html">Rank and shape</a> both do this, so an atom can be considered to have the same dimensions as a unit array: rank 0 and shape <code><span class='Bracket'>⟨⟩</span></code>. An atom is also considered a kind of unit, but it's not a unit array.</p>
<p>Atoms are displayed as plain values, while enclosed atoms, that is, depth-1 unit arrays, are shown with an array display.</p>
<a class="replLink" title="Open in the REPL" target="_blank" href="https://mlochbaum.github.io/BQN/try.html#code=MyAgICAjIEF0b20KPDMgICAjIEFycmF5CiczJyAgIyBBdG9t">↗️</a><pre> <span class='Number'>3</span> <span class='Comment'># Atom
</span>3