Path: ...!weretis.net!feeder8.news.weretis.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Keith Thompson Newsgroups: comp.arch Subject: Re: COBOL, Article on new mainframe use Date: Wed, 21 Aug 2024 02:06:35 -0700 Organization: None to speak of Lines: 26 Message-ID: <87o75mb5yc.fsf@nosuchdomain.example.com> References: <87zfp6bst1.fsf@nosuchdomain.example.com> <76220abd8c5b8ca50c4b7a5515d2a466@www.novabbs.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Date: Wed, 21 Aug 2024 11:06:36 +0200 (CEST) Injection-Info: dont-email.me; posting-host="7a2cb821a5a9c1554a17483648fb73a0"; logging-data="4006544"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1//utOHM6uGzsFpVid397xy" User-Agent: Gnus/5.13 (Gnus v5.13) Cancel-Lock: sha1:RzTNyWMWPSGSkyvrDPNzZcItocE= sha1:6QnXSb55wLa+uHCqDzgWQsj4hjY= Bytes: 2062 mitchalsup@aol.com (MitchAlsup1) writes: > On Wed, 21 Aug 2024 0:52:58 +0000, Keith Thompson wrote: >> Lawrence D'Oliveiro writes: >>> On Tue, 20 Aug 2024 11:51:14 -0400, EricP wrote: >> [...] >>>> x^17 = ((((x^2)^2)^2)^2)*x >>>> >>> >>> I’d really like to see how you’d write that in COBOL ... >> >> COMPUTE X17 = ((((X**2)**2)**2)**2)*X > > Why not:: > > COMPUTE x17 = x**17 > > There are compilers these days that produce the above from > the simpler evaluation. Sure, I wouldn't complexify x**17 to ((((X**2)**2)**2)**2)*X without a very good reason. I was just giving the most direct answer to the question. -- Keith Thompson (The_Other_Keith) Keith.S.Thompson+u@gmail.com void Void(void) { Void(); } /* The recursive call of the void */