| Deutsch English Français Italiano |
|
<20250416181840.00003d96@yahoo.com> View for Bookmarking (what is this?) Look up another Usenet article |
Path: news.eternal-september.org!eternal-september.org!.POSTED!not-for-mail
From: Michael S <already5chosen@yahoo.com>
Newsgroups: comp.lang.c
Subject: Re: Loops (was Re: do { quit; } else { })
Date: Wed, 16 Apr 2025 18:18:40 +0300
Organization: A noiseless patient Spider
Lines: 24
Message-ID: <20250416181840.00003d96@yahoo.com>
References: <vspbjh$8dvd$1@dont-email.me>
<20250413072027.219@kylheku.com>
<vtgpce$39229$1@dont-email.me>
<vti2ki$g23v$1@dont-email.me>
<vtin99$vu24$1@dont-email.me>
<vtiuf0$18au8$1@dont-email.me>
<vtj97r$1i3v3$1@dont-email.me>
<vtl166$36p6b$1@dont-email.me>
<vtlcg0$3f46a$2@dont-email.me>
<20250415053852.166@kylheku.com>
<vtm4ae$6d5j$1@dont-email.me>
<H7yLP.2056536$OrR5.1414451@fx18.iad>
<vtmgj8$g81k$1@dont-email.me>
<vtnfjj$1gk91$1@dont-email.me>
<vto4fu$23kmr$1@dont-email.me>
<vtofus$2bntf$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit
Injection-Date: Wed, 16 Apr 2025 17:18:43 +0200 (CEST)
Injection-Info: dont-email.me; posting-host="a5b6afe1e2db320795a254109bc9c05b";
logging-data="2364728"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/S9a30BAY5nBaqMBN2GnDE55ZiQhczH/k="
Cancel-Lock: sha1:+hl3QTqkUrKI7p98UnKmCr/Jcxo=
X-Newsreader: Claws Mail 4.1.1 (GTK 3.24.34; x86_64-w64-mingw32)
On Wed, 16 Apr 2025 10:47:56 -0400
James Kuyper <jameskuyper@alumni.caltech.edu> wrote:
> bart <bc@freeuk.com> writes:
> >On 16/04/2025 06:35, Janis Papanagnou wrote:
>
> >
> >So here, 0% of such loops have a step other than 1. THAT's what I
> >mean by 'unusual'.
>
> The files easily accessible to me contain 13965 for statements, of
> which 596 used a step other than 1.
>
In quoted statement "1" was meant to cover both +1 and -1.
I would be surprised to find out that non-units strides are relatively
common (say, above 0.1%) outside of several specialized fields, like
linear algebra and image processing.
There are yet other fields where we can encounter increments that are
non-constant throughout duration of the loop. Bart would probably say
that such loops do not count, in both senses. I.e. they are not
counting loops, but forms of while loop.