Sujet : Re: on allowing "int a" definition everywhere
De : fir (at) *nospam* grunge.pl (fir)
Groupes : comp.lang.cDate : 27. Aug 2024, 09:46:52
Autres entêtes
Organisation : i2pn2 (i2pn.org)
Message-ID : <7ea05965a67fa09d4ebd0b6ec53109dcb0b12f76@i2pn2.org>
References : 1 2
User-Agent : Mozilla/5.0 (Windows NT 5.1; rv:27.0) Gecko/20100101 Firefox/27.0 SeaMonkey/2.24
Lawrence D'Oliveiro wrote:
On Sun, 25 Aug 2024 12:40:39 +0200, fir wrote:
>
Lawrence D'Oliveiro wrote:
>
Somehow along the line from BCPL to B to C, one useful feature was
lost: the ability to have a value-returning statement block inside an
expression.
>
if so thats probably sad, though i dont know how it looked like
>
The construct looks like
>
VALOF $( ... «stmts»; RESULTIS «return-value» $)
>
it is good to things return value and good to be able to combine it
as i sait for example i consider such loops
10'x //ten tiem execute x
print (10'x+=x)/10
would be equivalent of
for(int i=0; i<10; i++) x+=x;
print(x/10)
(and its still c, just with shorted syntax not python et sort)