Article View: comp.lang.c
Article #625Re: Taming The Switch-Statement
From: Keith Thompson
Date: Wed, 21 Oct 2026 01:23
Date: Wed, 21 Oct 2026 01:23
36 lines
3169 bytes
3169 bytes
David Brown <david.brown@hesbynett.no> writes:
> On 19/10/2026 23:27, Janis Papanagnou wrote:
[...]
>> * a b PN (Polish Notation)
>
> There is no term "Polish Notation" - except as occasionally used to
> mean /postfix/ as a short form of "Reverse Polish Notation". RPN was
> invented, or at least popularised, by the Polish logician Jan
> Łukasiewicz (I admit to looking that up on Wikipedia!). There is no
> "PN" opposite.
Yes, there most certainly is, and "* a b" is a good example of it.
https://en.wikipedia.org/wiki/Polish_notation
Jan Łukasiewicz invented what we now call Polish notation in 1924.
`+ 3 4` is an example (which yields 7). Lisp syntax is more or
less Polish notation with added parentheses. (I'm sure the phrase
"more or less" is doing a lot of work.)
Reverse Polish Notation, RPN, is very well known because it's
used by some calculators, particularly those made by HP. It's a
postfix notation. An example of RPN is `3 4 +` (which also yields 7).
I've never seen the term "Polish Notation", without "Reverse", used
to refer to postfix notation. PN is prefix; RPN is postfix.
I see that Janis already pointed out your error. I'm disappointed
that your followup did not acknowledge it. (I'm not commenting on the
rest of what Janis wrote.)
[...]
--
Keith Thompson (The_Other_Keith) Keith.S.Thompson+u@gmail.com
void Void(void) { Void(); } /* The recursive call of the void */
Technical Details
Message-ID:
<11b946k$3h5oi$1@kst.eternal-september.org>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!kst.eternal-september.org!.POSTED!not-for-mailReferences:
<119qf6l$2rmg3$1@dont-email.me> <11arjmc$2qid7$1@dont-email.me> <11at5vi$5vu$1@reader2.panix.com> <11auad0$3no1k$1@dont-email.me> <11aupfl$3ul$1@reader2.panix.com> <11avmfb$55rt$1@dont-email.me> <11b2a6d$131h6$1@dont-email.me> <20261018172446.00002d43@yahoo.com> <11b2mqu$16mof$3@dont-email.me> <20261018182627.00001934@yahoo.com> <11b2r36$3pvda$8@dont-email.me> <20261018193201.00000b13@yahoo.com> <11b56s8$1kr9u$2@dont-email.me> <20261019223538.00006521@yahoo.com> <11b61v8$1kr9u$6@dont-email.me> <11b78i5$2m8c9$4@dont-email.me>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!kst.eternal-september.org!.POSTED!not-for-mail From: Keith Thompson <Keith.S.Thompson+u@gmail.com> Newsgroups: comp.lang.c Subject: Re: Taming The Switch-Statement Date: Tue, 20 Oct 2026 18:23:32 -0700 Organization: None to speak of Lines: 36 Message-ID: <11b946k$3h5oi$1@kst.eternal-september.org> References: <119qf6l$2rmg3$1@dont-email.me> <11arjmc$2qid7$1@dont-email.me> <11at5vi$5vu$1@reader2.panix.com> <11auad0$3no1k$1@dont-email.me> <11aupfl$3ul$1@reader2.panix.com> <11avmfb$55rt$1@dont-email.me> <11b2a6d$131h6$1@dont-email.me> <20261018172446.00002d43@yahoo.com> <11b2mqu$16mof$3@dont-email.me> <20261018182627.00001934@yahoo.com> <11b2r36$3pvda$8@dont-email.me> <20261018193201.00000b13@yahoo.com> <11b56s8$1kr9u$2@dont-email.me> <20261019223538.00006521@yahoo.com> <11b61v8$1kr9u$6@dont-email.me> <11b78i5$2m8c9$4@dont-email.me> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Date: Wed, 21 Oct 2026 01:23:32 +0000 (UTC) Injection-Info: kst.eternal-september.org; logging-data="3708690"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18GAR+oB7LE/RdoGi4lKDI3"; posting-host="e330dd7faf054fe4ae34cec694f6f43b" User-Agent: Gnus/5.13 (Gnus v5.13) Cancel-Lock: sha1:FgnbtFauYPjQDH8YtMRcRD4GLVI= sha256:xc3KiSEEqu8rRFGZKFfb1+tx39bYs0YTGRuF+Tc6HLA= sha1:H57UoYMHzcho/kFGZMONjzfJAbo= sha256:NgqDgN2pqlpRAYMQrG3MgOBvlmaV3DkTlHh82myuiDA=