Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

“Indexing” revision #4

Closed
23 tasks done
rodrigogiraoserrao opened this issue Jun 7, 2021 · 1 comment
Closed
23 tasks done

“Indexing” revision #4

rodrigogiraoserrao opened this issue Jun 7, 2021 · 1 comment

Comments

@rodrigogiraoserrao
Copy link

rodrigogiraoserrao commented Jun 7, 2021

There was a formatting issue in that the section “Pick” shows the raw markdown (## Pick) instead of the header.

Revision

Here I include all of the things that, to the best of my knowledge and experience, should be changed/corrected.

  • Typos and other minor issues:
    • similar to how c-like languages → similar to how C-like languages
    • one or more enclosed vectors each with → one or more enclosed vectors, each with
    • i.e → i.e.
    • bit-boolean arrays → bit-Boolean arrays
    • using a boolean array → using a Boolean array
    • But in the more general case we need not → But, in the more general case, we need not
    • A monadic pick means pick first element. → A monadic pick means "pick first element"./A monadic pick picks the first element.
    • Reach Indexing → Reach indexing

To consider

In here I include things that, from my point of view, would be nice additions/modifications. Tick them as you ponder on them, feel free to disregard.

  • Indexing with [] or ⌷ returns the box, not the element, although if the element is a simple scalar, it’s the same thing. → Indexing with [] or ⌷ returns the box, not the element. However, if the element is a simple scalar, it’s the same thing. (The 4 , in the sentence made it a weird sentence to read.)
  • Use backticks when talking about code in your prose:
    • Indexing with [] or ⌷ returns → Indexing with [ ] or returns
  • Say something, somewhere, about the 4-line setup you use (setting ⎕IO, ]box, ]rows, assert); maybe a comment in the code block itself
  • Remove the settings you don't need, especially the assert
  • but it’s clear for a nested array: → but the distinction/difference is clear for a nested array:
  • When you introduce squad ,
    • you say that [ ] do not bind strictly right-to-left, which I don't think is a sentence many people will understand;
    • then you proceed to saying that fixes some [ ] issues and introduces new ones, but I don't think you say which ones (maybe I missed them?);
    • finally, you say “The binding is now APL-sensible:” and show three examples of indexing with ; were those examples supposed to show how the binding is now sensible? To me, it felt like the examples simply showed how works.
  • Pick a cell from axis 1, i.e column 1 in our case: → For example, here is how we pick cell 2 from axis 1 (i.e., the third column):
     2[1]m

(I think it is important to index into a cell that is not the same number as the axis, so as to make the distinction between the axis and the indices abundantly clear)

  • change
select  0 0 1 0 1 1 0 1 1 0  Select elements 2, 4, 5, 7 and 8
data    10

into

 data    0 1 2 3 4 5 6 7 8 9
 select  0 0 1 0 1 1 0 1 1 0  Select elements 2, 4, 5, 7 and 8
xpqz added a commit that referenced this issue Jun 9, 2021
@xpqz
Copy link
Owner

xpqz commented Jun 9, 2021

Fixed in 5f9c136

@xpqz xpqz closed this as completed Jun 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants