comp.lang.ada
 help / color / mirror / Atom feed
From: Georg Bauhaus <rm.dash-bauhaus@futureapps.de>
Subject: Re: Verified compilers?
Date: Fri, 09 Mar 2012 01:44:01 +0100
Date: 2012-03-09T01:44:01+01:00	[thread overview]
Message-ID: <4f595251$0$7619$9b4e6d93@newsspool1.arcor-online.net> (raw)
In-Reply-To: <ezfn0og1qfov.14k34sxoky5ke.dlg@40tude.net>

On 08.03.12 21:40, Dmitry A. Kazakov wrote:
> On Thu, 08 Mar 2012 20:02:25 +0200, Niklas Holsti wrote:

>> How else could you explain why "2*3+4*5" means 26, and not 70, nor
>> something else?
>
> Explain? It is a subject of proof. There are more than one way to do it.
> BTW the "meaning" you are advocating for looks rather something like
> 23*45*+.

No!

It must mean

  "at least zero twos followed by a three or more of these,
   with maybe fours coming next, and finally a five".

+ is clearly a macro. And, for proof, in which school did they ever
teach that a star denotes multiplication?  A Kleene star is a Kleene
star.


No!

"2*3+4*5" must have a syntax error. What it really means is this:

Python>>> "2"*3+"4"*5
'22244444'


What? No!

Dumb animal, this Python. The mathematical interpretation is obviously
right:

Perl-DB<1> print "2"*3+"4"*5
26


Excuse me, no! A Programming Language was there first, and it says,

*     2*3+4*5
  Inf
Because, obviously,
*     2*1027
  Inf


Uh, no, not any more.

Are you guys still using that old APL dialect? Look at J for the
real meaning:

    2*3+4*5
46
Because
    3+4*5
23


Nah!

Ever since 1969, SNOBOL-4 clearly shows that
	2*3+4*5
         	2*3+4*5
         	^
stdin:1: *** Illegal character in element

Because a string needs quotes around it, for one thing!



Right, that's been known by Lispers for a long time:

* 2*3+4*5

Error in KERNEL::UNBOUND-SYMBOL-ERROR-HANDLER:  the variable 2*3+4*5 is unbound.
    [Condition of type UNBOUND-VARIABLE]




Really, you can't remove the quotes from a string and expect
it to have meaning? Look, all it means when output is just itself!


SNOBOL4 (Version 3.11, May 19, 1975)
     Bell Telephone Laboratories, Incorporated

	OUTPUT = "2*3+4*5"
END
No errors detected in source program

2*3+4*5
Normal termination at level 0


--
> LISP
* 2 + 3 * 4 + 5

2
*
2
*
3
*
3
*
4
*
4
*
5
* (QUIT)




  reply	other threads:[~2012-03-09  0:46 UTC|newest]

Thread overview: 63+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-21 15:42 Verified compilers? Yannick Duchêne (Hibou57)
2012-02-24  1:41 ` Shark8
2012-02-24  8:52   ` Georg Bauhaus
2012-02-24 17:36   ` Peter C. Chapin
2012-03-06  1:27 ` Randy Brukardt
2012-03-06 17:24   ` Shark8
2012-03-06 17:43     ` Dmitry A. Kazakov
2012-03-06 19:03       ` Shark8
2012-03-07  5:33       ` Yannick Duchêne (Hibou57)
2012-03-07  9:12         ` Dmitry A. Kazakov
2012-03-07 17:49           ` Niklas Holsti
2012-03-07 20:17             ` Dmitry A. Kazakov
2012-03-07 23:28               ` Usefulness of Formal Notions in Programming (was: Verified compilers?) Georg Bauhaus
2012-03-08  9:24                 ` Usefulness of Formal Notions in Programming Dmitry A. Kazakov
2012-03-08 10:30                   ` Nasser M. Abbasi
2012-03-08 12:37                     ` Dmitry A. Kazakov
2012-03-08  0:42               ` Verified compilers? Randy Brukardt
2012-03-08  9:25                 ` Dmitry A. Kazakov
2012-03-08 18:10                   ` Niklas Holsti
2012-03-08 20:41                     ` Dmitry A. Kazakov
2012-03-08 18:02               ` Niklas Holsti
2012-03-08 20:40                 ` Dmitry A. Kazakov
2012-03-09  0:44                   ` Georg Bauhaus [this message]
2012-03-09 22:13                   ` Niklas Holsti
2012-03-10 10:36                     ` Dmitry A. Kazakov
2012-03-10 20:35                       ` Niklas Holsti
2012-03-11  9:47                         ` Dmitry A. Kazakov
2012-03-11 22:22                           ` Niklas Holsti
2012-03-12  5:12                             ` Niklas Holsti
2012-03-12  9:43                             ` Dmitry A. Kazakov
2012-03-14  8:36                               ` Niklas Holsti
2012-03-14  9:24                                 ` Georg Bauhaus
2012-03-14 11:14                                   ` REAL (was: Verified compilers?) stefan-lucks
2012-03-14 12:59                                     ` REAL Dmitry A. Kazakov
2012-03-14 13:30                                       ` REAL Georg Bauhaus
2012-03-14 13:51                                         ` REAL Dmitry A. Kazakov
2012-03-14 20:37                                           ` REAL Brian Drummond
2012-03-14 21:52                                             ` REAL Dmitry A. Kazakov
2012-03-14 13:52                                         ` REAL georg bauhaus
2012-03-14 17:42                                         ` REAL Jeffrey Carter
2012-03-14 10:14                                 ` Verified compilers? Dmitry A. Kazakov
2012-03-14 20:13                                   ` Niklas Holsti
2012-03-11 10:55                         ` Georg Bauhaus
2012-03-10 13:46                     ` Brian Drummond
2012-03-07  1:00     ` Randy Brukardt
2012-03-07 12:42   ` Stuart
2012-03-08  1:06     ` Randy Brukardt
2012-03-08  9:04       ` Jacob Sparre Andersen
2012-03-08  9:37         ` Dmitry A. Kazakov
2012-03-08 11:23           ` Simon Wright
2012-03-08 12:27             ` Dmitry A. Kazakov
2012-03-08 10:23         ` Brian Drummond
2012-03-08 23:38           ` Bill Findlay
2012-03-09 13:56             ` Brian Drummond
2012-03-09 14:43               ` Shark8
2012-03-09 21:51                 ` Brian Drummond
2012-03-09 15:49               ` Bill Findlay
2012-03-09 20:34                 ` Brian Drummond
2012-03-09 19:40               ` Jeffrey Carter
2012-03-09 20:39                 ` Brian Drummond
2012-03-09 23:59               ` phil.clayton
2012-03-08 15:23         ` Peter C. Chapin
2012-03-09  2:04         ` Randy Brukardt
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox