From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 109fba,baaf5f793d03d420 X-Google-Attributes: gid109fba,public X-Google-Thread: 1014db,6154de2e240de72a X-Google-Attributes: gid1014db,public X-Google-Thread: 103376,97188312486d4578 X-Google-Attributes: gid103376,public X-Google-Thread: 10db24,2243248c6a74be5 X-Google-Attributes: gid10db24,public From: dewar@cs.nyu.edu (Robert Dewar) Subject: Re: Should I learn C or Pascal? Date: 1996/07/21 Message-ID: #1/1 X-Deja-AN: 170033680 references: <4sord0$l0k@solaria.cc.gatech.edu> <4su04n$fa6@hermes.acs.unt.edu> <4su73k$r68@sunsrv12.clr.com> organization: Courant Institute of Mathematical Sciences newsgroups: comp.lang.c,comp.lang.c++,comp.lang.ada,comp.edu Date: 1996-07-21T00:00:00+00:00 List-Id: Steve said "| poster. To explain that a little better: you can never, EVER "test | the correctness" of an *algorithm* by executing it. I don't care how | you design your test cases, the ONLY way to show the correctness of an | algorithm is with a formal mathematical proof. Of course, | implementations are good for demonstrating the INcorrectness of some | algorithms! :-)" Well it is a reasonable guess that Steve is pretty new to the field and is repeating what he has been taught. But still, this concentration on correctness seems a mistake to me, and it particularly seems a mistake to concentrate on correctness to the exclusion of pragmatic understanding of the real issues. Steve, you need to understand that correctness is just one aspect of a program. Correct programs are not necessarily usable or acceptable, and incorrect programs are often both usable and acceptable. There are two issues here. Correctness only reflects the match between a program and it spec (Note; i know we had a discussion about the confusion caused by taking a general term like correctness and using in this restricted sense, but that is clearly what Steve is talking about when he talks about a mathematic proof, since clearly you cannot proove a program correct if you use the more general informal meaning of correct :-) But: a) how do you know the spec is correct (now we are using the informal sense of the term -- since sooner or later you have to track back to the real world, and at the point you do, the notion of mathematical proof fails you. b) what if the spec is not formalizable ("make the screen appearence aesthetically pleasing", "generate good error messages" etc.) Such specs can *only* be realized via testing, since they are subjective, but often subjective requirements like this are as important as anything else (is the interface of Windows 95 correct?????) Proof of correctness is an important tool, but accepting the orthodoxy that it is the only useful approach and that testing of implementations is useless reflects a rather large gap between your thinking and the real world!