Article View: pl.comp.lang.pascal
Article #92637Re: WHile a For
From: Daniel Janus
Date: Sat, 18 Oct 2008 10:42
Date: Sat, 18 Oct 2008 10:42
32 lines
1497 bytes
1497 bytes
Dnia 18.10.2008 Andrzej Grażyński <grazynsk@petex.com.pl> napisał/a:
> Już było, ale nie szkodzi powtórzyć:
>
> czym się róznią konstrukcje:
>
> var
> i, a, b: integer;
>
> {1}
>
> for i := a to b do
> begin
> { jakaś sekwencja }
> end;
>
>
> {2}
>
> i := a;
>
> while i <= b do
> begin
> { ta sama sekwencja }
> inc(i);
> end;
Tym, że w drugim przypadku wpadamy w pętlę nieskończoną dla b = 32767?
--
Daniel 'Nathell' Janus, moveat@nathell.korpus.pl, http://korpus.pl/~nathell
Nothing smells more like a slaughterhouse than a graduate seminar.
-- Leonard Cohen, "The Favourite Game"
Technical Details
Message-ID:
<slrngfjfd9.oc5.przesunmalpe@students.mimuw.edu.pl>Path:
mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.gazeta.pl!not-for-mailReferences:
<20080905121945.03f2cdf2.solaris@be.inspired> <gdcdu2$27s$1@news.onet.pl>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.gazeta.pl!not-for-mail From: Daniel Janus <przesunmalpe@nathell.korpus.pl> Newsgroups: pl.comp.lang.pascal Subject: Re: WHile a For Date: Sat, 18 Oct 2008 10:42:49 +0000 (UTC) Organization: "Portal Gazeta.pl -> http://www.gazeta.pl" Lines: 32 Message-ID: <slrngfjfd9.oc5.przesunmalpe@students.mimuw.edu.pl> References: <20080905121945.03f2cdf2.solaris@be.inspired> <gdcdu2$27s$1@news.onet.pl> Reply-To: przesunmalpe@nathell.korpus.pl NNTP-Posting-Host: students.mimuw.edu.pl Mime-Version: 1.0 X-Trace: inews.gazeta.pl 1224326569 14975 193.0.96.129 (18 Oct 2008 10:42:49 GMT) X-Complaints-To: usenet@agora.pl NNTP-Posting-Date: Sat, 18 Oct 2008 10:42:49 +0000 (UTC) X-User: anonymous User-Agent: slrn/0.9.8.1pl1 (Linux) Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit