Liste des Groupes | Revenir à cl c |
On 2024-06-02, Lew Pitcher <lew.pitcher@digitalfreehold.ca> wrote:
>I've always considered>
for (;;)
preferable over
while (1)
Of course it is preferable. The idiom constitutes the language's direct
support for unconditional looping, not requiring that to be requested by
an extraneous always-true expression.
>
Using while (1) or while (true) is like i = i + 1 instead
of ++i, or while (*dst++ = *src++); instead of strcpy. [...]
Les messages affichés proviennent d'usenet.