* [TUHS] Discuss of style and design of computer programs from a user standpoint
@ 2017-05-07 18:19 Doug McIlroy
2017-05-07 18:50 ` William Cheswick
0 siblings, 1 reply; 3+ messages in thread
From: Doug McIlroy @ 2017-05-07 18:19 UTC (permalink / raw)
> tr -cs A-Za-z '\n' |
> tr A-Z a-z |
> sort |
> uniq -c |
> sort -rn |
> sed ${1}q
>
> This is real genius.
Not genius. Experience. In the Bentley/Knuth/McIlroy paper I said,
"[Old] Unix hands know instinctively how to solve this one in a jiffy."
While that is certainly true, the script was informed by my having
written "spell", which itself was an elaboration of a model
pioneered by Steve Johnson. By 1986, when BKM was published,
the lore was baked in: word-processing scripts in a similar
vein were stock in trade.
A very early exercise of this sort was Dennis Ritchie's
enumeration of anagrams in the unabridged Merriam-Webster.
Since the word list barely fit on the tiny disk of the time,
the job entailed unimaginable marshalling of resources. I
was mightily impressed then, and still am.
Doug
^ permalink raw reply [flat|nested] 3+ messages in thread
* [TUHS] Discuss of style and design of computer programs from a user standpoint
2017-05-07 18:19 [TUHS] Discuss of style and design of computer programs from a user standpoint Doug McIlroy
@ 2017-05-07 18:50 ` William Cheswick
2017-05-07 22:03 ` Larry McVoy
0 siblings, 1 reply; 3+ messages in thread
From: William Cheswick @ 2017-05-07 18:50 UTC (permalink / raw)
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 747 bytes --]
> On 7May 2017, at 2:19 PM, Doug McIlroy <doug at cs.dartmouth.edu> wrote:
>
> Not genius. Experience.
It’s the pipe that was genius. When I first heard the idea, I thought it was preposterous. My
programs’ outputs were designed for the line printer, with carriage control characters. How
could this idea be useful?
These tools are powerful--I co-founded a company out of network probe software mostly designed
around filters. And it scales beautifully to multi-core computing. I had movie visualization software
suddenly nearly double in speed one day. They had doubled the number of CPUs in the ferric cluster.
My favorite filter: the unsort (or scramble) command.
Honeyman’s “idiom” command:
sort | uniq -c | sort -rn
^ permalink raw reply [flat|nested] 3+ messages in thread
* [TUHS] Discuss of style and design of computer programs from a user standpoint
2017-05-07 18:50 ` William Cheswick
@ 2017-05-07 22:03 ` Larry McVoy
0 siblings, 0 replies; 3+ messages in thread
From: Larry McVoy @ 2017-05-07 22:03 UTC (permalink / raw)
On Sun, May 07, 2017 at 02:50:52PM -0400, William Cheswick wrote:
> My favorite filter: the unsort (or scramble) command.
> sort | uniq -c | sort -rn
I use that one all the time. Super handy.
--
---
Larry McVoy lm at mcvoy.com http://www.mcvoy.com/lm
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2017-05-07 22:03 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-07 18:19 [TUHS] Discuss of style and design of computer programs from a user standpoint Doug McIlroy
2017-05-07 18:50 ` William Cheswick
2017-05-07 22:03 ` Larry McVoy
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).