From: Doug McIlroy <doug@cs.dartmouth.edu>
To: tuhs@tuhs.org, jnc@mercury.lcs.mit.edu
Subject: Re: [TUHS] block operations in editors, was My EuroBSDcon talk
Date: Tue, 17 Sep 2019 13:31:52 -0400 [thread overview]
Message-ID: <201909171731.x8HHVq2L096688@tahoe.cs.Dartmouth.EDU> (raw)
Noel Chiappa wrote:
> > From: Doug McIlroy
>
> > the absence of multidemensional arrays in C.
>
>?? From the 'C Reference Manual' (no date, but circa 'Typesetter C'), pg. 11:
>
> "If the unadorned declarator D would specify an n-dimensional array .. then
> the declarator D[in+1] yields an (n+1)-dimensional array"
>
>
>I'm not sure if I've _ever_ used one, but they are there.
Yes, C allows arrays of arrays, and I've used them aplenty.
However an "n-dimensional array" has one favored dimension,
out of which you can slice an array of lower dimension. For
example, you can pass a row of a 2D array to a function of a
1D variable, but you can't pass a column. That asymmetry
underlies my assertion. In Python, by contrast, n-dimensional
arrays can be sliced on any dimension.
Doug
next reply other threads:[~2019-09-17 17:32 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-09-17 17:31 Doug McIlroy [this message]
2019-09-18 4:47 ` Steve Johnson
2019-09-18 4:52 ` Jon Steinhart
-- strict thread matches above, loose matches on Subject: below --
2019-09-17 15:36 Noel Chiappa
2019-09-17 11:34 Thomas Paulsen
2019-09-17 0:20 Doug McIlroy
2019-09-17 0:42 ` G. Branden Robinson
2019-09-17 2:02 ` George Michaelson
2019-09-17 11:01 ` Thomas Paulsen
2019-09-17 1:25 ` Bakul Shah
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201909171731.x8HHVq2L096688@tahoe.cs.Dartmouth.EDU \
--to=doug@cs.dartmouth.edu \
--cc=jnc@mercury.lcs.mit.edu \
--cc=tuhs@tuhs.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).