Path: utzoo!utgpu!news-server.csri.toronto.edu!mailrus!ncar!boulder!gore!jacob From: jacob@gore.com (Jacob Gore) Newsgroups: comp.lang.c Subject: Re: problems/risks due to programming language, stories requested Message-ID: <470009@gore.com> Date: 15 Mar 90 23:26:19 GMT References: <9790@medusa.cs.purdue.edu> Reply-To: jacob@gore.com (Jacob Gore) Organization: Gore Enterprises Lines: 27 / comp.lang.c / a563@mindlink.UUCP (Dave Kirsch) / Mar 14, 1990 / > Do this in Pascal: > > switch (i) { > case 2 : /* Add 2 to j */ > j++; > case 1 : /* Add 1 to j */ > j++; > case 0 : /* Print j out */ > printf("%d\n", j); > break; > default : > printf("Illegal value in switch.\n"); > abort(); > } if i in [0..2] then begin j := j + i; writeln(j); end else begin writeln("Illegal value in switch.\n"); abort; end; Jacob -- Jacob Gore Jacob@Gore.Com boulder!gore!jacob