--- In [email protected], "kocmotex" <kocmo...@...> wrote: > > --- In [email protected], Pedro Izecksohn <izecksohn@> wrote: > > > > --- kocmotex wrote: > > > ... the inability of academia to shift gears. After all, if > > > some of the other free C compilers were taught, such as Pelles C, > > > lcc-win32, Dev-C, etc, the academia might have to re-write some of > > > their arcane quiries, such as triple pre-or-postfix notation, viz. > > > +++y, c---, et al. > > > svegda, > > > > Could you expand about this topic? > > > > I wrote a small application to illustrate this topic, but I have > no idea on how Turbo C would compile it: > > > > #include <stdio.h> > > #include <stdlib.h> > > > > int main (int argc, char **argv) { > > if (argc<3) { > > fprintf (stderr, "Usage: problem number number\nWhere number is a > decimal integer.\n"); > > return EXIT_FAILURE; > > } > > int a = atoi (argv[1]); > > printf ("The first argument was %d.\n", a); > > int b = atoi (argv[2]); > > int c = a---b; > > printf ("%d = %d---%d\n", c, a, b); > > c = a+++b; > > printf ("%d = %d+++%d\n", c, a, b); > > return 0; > > } > > > > I must go to sleep now. > > > Excuse the hiatus. Yes. Yes. Yes. The reading of specifications is > extremely conducive to gross boredom and sleep. But, my friend, > therein is where your answer is hidden. The C standards do NOT admit > to the use of triple pre-or-postfix notation. And if you try to use > it, you will discover that the results are idiosyncratic to the > compiler used. I think that this is a question to ascertain how brain > dead the applicant is. > > svegda, Kocmotex > Excuse me again. What I should have added to the preceding comment is that there are many times when we are asked an arcane and ludicrous question. We are so taken aback by how ridiculousness the question is that we begin to question ourselves. Have we really missed something that was obvious, or did I fall asleep during that lecture? The truth is that the question is so off the wall, that we are taken by surprise.
If statements are only used to make a CHOICE between bifurcated conditions. The question applies to a NON-bifurcated situation and as such is wholly meaningless. A unique feature of the C language is the use of pre-and-post mathematical notation which avoids the old FORTRAN statement, g = g + 1, et cetera. I hope that this helps to clear the air regarding these interview questions. svegda, Kocmotex
