Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10 5/3/83; site hou5e.UUCP Path: utzoo!linus!decvax!genrad!mit-eddie!mit-vax!eagle!hou5h!hou5a!hou5d!hou5e!mat From: mat@hou5e.UUCP Newsgroups: net.lang.c Subject: Re: "Break" and other ways out of loops and switches Message-ID: <751@hou5e.UUCP> Date: Sat, 27-Aug-83 14:48:15 EDT Article-I.D.: hou5e.751 Posted: Sat Aug 27 14:48:15 1983 Date-Received: Mon, 29-Aug-83 16:52:12 EDT References: <302@ihuxq.UUCP>, <357@nsc.uucp>, <179@ut-sally.UUCP> Organization: American Bell ED&D, Holmdel, NJ Lines: 24 If you only permit the labels for multi-level breaks to label blocks, you have a mechanism that does away with the last excuse for using gotos, and is much cleaner than the preprocessor kludge you advocate. FLAME ON! Goto's are not INHERENTLY evil (I hope MR. Djikstra is reading this!). Goto's are bad because they require discipline in use and because more disciplined constructs reflect well the structure of MOST problems and, therefor, are appropriate for MOST programming. There are some problems that are not clearly written this way. A few problems look like finite state automata. They CAN be written as loops containing switches and diddling with state variables. This is an unnatural solution, however, and usually error-prone. It is usually better to write the program like the problem. A word on program state variables: FORTRAN provides the ASSIGN statement, which is almost tailor-made to the uses of state variables. Yet we seem to have little good use made of the ASSIGN. Why? Could it be because state variables are a bad thing? Mark Terribile Duke of deNet