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=2.1 required=5.0 tests=BAYES_40,INVALID_MSGID, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,4ab5219b8ac31cbd,start X-Google-Attributes: gid103376,public From: Al Christians Subject: GOTO Considered ... Date: 1997/06/11 Message-ID: <339F84A4.1253@easystreet.com>#1/1 X-Deja-AN: 247911766 Sender: Ada programming language References: Comments: Gated by NETNEWS@AUVM.AMERICAN.EDU Organization: Trillium Resources Corporation Reply-To: achrist@easystreet.com Newsgroups: comp.lang.ada Date: 1997-06-11T00:00:00+00:00 List-Id: I have seen one application in which the GOTO statement worked very well. The program was a game (text mode, circa 1980) that depicted the movement of an adventurer through a castle of many chambers. I was helping an adolescent who was born after I started programming try to learn something about propitious techniques for writing software. Well in that genre, which was very popular amongst people of that age programming Basic in that era, the GOTO could be part of a very well-designed program. When you went to a chamber of the castle, it didn't matter where you went there from -- there was no need to ever RETURN or even to GOBACK. The program made heavy use of GOTO's, but it met my definition of well-structured, i.e. the structure of the program was obviously in accord with the structure of the problem. This didn't get me to love the GOTO -- I doubt that I've written as many GOTO's since then as that one program contained. But, that little kid's code convinced me that any programming language feature, no matter how inherently worthless, is likely to be wonderful when used correctly in the correct situation. (I'll even allow that a Fortran kind of guy might have solved the same problem just as elegantly with an FSM using one or more computed GOTO's) Al