A
Andrew Poelstra
I understand the question and I understand straightforward answers to
the question. I have written a fair amount of above basic programmes
in C therefore it has been possible for me to become more than a basic
user of the language without knowing the answer to the question.
Since you're claiming that it would answer my question can you explain
what
series of arguments starting from the result of the experiment and I
don't know
which other premises would lead me to conclude that the behaviour I
observed
was standard as opposed to implementation defined ?
Otherwise , Chris may know the answer to the question but he claimed
that the
experiment would offer me "far more insight". I don't know what this
substantial
amount of insight is supposed to be. I'm not even sure whether an
answer to my
question is supposed to be part of this insight.
The replies in the thread have offered me insight. The reply by Keith
above for
example or the quote form the standard or the comparison between macros
and
operators given in a different post (not quoted here). I wouldn't have
gotten any
of that from an experiment even if it would have answered my question
and I
don't believe it would have.
The standard quotations didn't help you, did they? As I type this people
are bickering over what they mean and whether they are relevant to your
question.
If you wanted the difference between functions and macros, you could have
posted that question.
He's a quick code sample for the experiment.
#include <stdio.h>
int main (void)
{
int r = 15;
r *= 3 + 5; /* r * 3 + 5 is 50, but r * (3 + 5) is 120. */
printf ("r is %d.\n", r); /* What does this output? */
return 0;
}
So you're saying that writing and running a small C programme would
teach me
about fishing. But I'm a city person you see , I don't fish. If I want
fish I just go
to the supermarket.
If you give a man a fish, he'll eat for a day. If you teach a man to fish,
he'll eat for a lifetime.
I'm saying that if I give you code, you'll have a program for a day,
but if you learn to code, you'll be able to program for life.