C Review

Jerry Whitnell jwhitnel at csi
Thu Jan 15 10:47:59 AEST 1987


In article <2313 at brl-adm.ARPA> you write:
>some opinions from other C programmers. Below is a list of some
>his statements. Is this guy for real? Your comments would be
>greatly appreciated. Incidentally, the text is not an intro
>text, it assumes the reader has finished a course in Pascal.
>
>"... 95% of all C programmers couldn't give you a good
>explanation of the term lvalue..."
False.  I would guess 1/3 to 1/2 could give you a definition.  95% couldn't
give you a complete and technically correct definition.

>
>"... Switch/case could be classified as rarely used and should be
>kept till later.
False.  Switch statements are a very useful and very commonly used construct.
I would guess 90+% of all C programs use at least one.

>
>"... very few C programmers know much about sizeof..."
False.  Most C programmers know and understand the uses of sizeof (even if
some don't use it when they should!)

>
>"... 99%  of  all  professional C  programmers  have no idea
>what typedef is all about, couldn't care less and probably
>won't ever need it."
False.  Most C programmers do know what typedef is, even though the construct
is relativly new to the language.  This is becauase most C programmer's are
also relativly new.

>
>"... 99%  of  all  professional C  programmers  have no idea
>what the comma operator is all about, couldn't care less and
>probably won't ever need it."
Probably true.  I use it, but wouldn't miss it if it wasn't there.

>
>"... Leave the comma operator altogether. An intro book is no
>place for obscure and unmaintainable tricks..."
>
True.

>"... Pointers to functions ... few C programmers understand
>them or would ever need them..."
False.  Anyone who has programmed the Macintosh needs to understand them
and use them.  Pointers to functions are a necessary and useful tool for
any professional programmer.

>
>"... a C programmer never needs to know what a byte is..."
False.  Understanding the byte is necessary to understand the technicques
of writing truly machine independent code.

My answers are based on 8+ years of C programming and of reading 1000's of
C programs written by all levels of programmers.



More information about the Comp.lang.c mailing list