473,387 Members | 1,899 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

about ANSI C Standard...

AmberJain
884 Expert 512MB
HELLO,

Is it necessary for a C programmer to have an ANSI C standard or it's sufficient to own Kernigham and Rithie's The C programming language?

I know that the ritchie's book is quite brief and precise. But still, do I need a ANSI C standard?

Also,
Which ANSI C standard should I prefer i.e. ANSI C89 or ANSI C99 to implement in my C programs?
Can you tell me pros and cons of both standards?
Also, is there a newer standard in existence better than ANSI C99?


Also,
Is ritchie's book's edition second (ANSI C) good or should I buy the latest edition of book? (the book is probably ANSI C89 based)


THANKS IN ADVANCE TO EVERYONE.................

============
AmbrNewlearner
============
Jun 11 '08 #1
8 2043
JosAH
11,448 Expert 8TB
C99 is the latest Standard and indeed K&R2 predates the first C89 Standard
but it is extremely good and considered 'the bible' of C. There are many C99
Standard drafts around because the commitee 'leaked' a bit in those days;
you can probably find a copy somewhere on the net. I bet you'll find something
in the usenet group comp.lang.c.moderated; check their FAQlist.

If you want to be a 'language lawyer' a copy of the Standard is a must; it doesn't
leave any room for guessing nor bluffing. Check for a file named n869 for one of
the latest draft texts.

kind regards,

Jos
Jun 12 '08 #2
AmberJain
884 Expert 512MB
C99 is the latest Standard and indeed K&R2 predates the first C89 Standard
but it is extremely good and considered 'the bible' of C. There are many C99
Standard drafts around because the commitee 'leaked' a bit in those days;
you can probably find a copy somewhere on the net. I bet you'll find something
in the usenet group comp.lang.c.moderated; check their FAQlist.

If you want to be a 'language lawyer' a copy of the Standard is a must; it doesn't
leave any room for guessing nor bluffing. Check for a file named n869 for one of
the latest draft texts.

kind regards,

Jos
THANKS JosAH...

BTW, what are your views about this question of mine?
Is ritchie's book's edition second (ANSI C) good or should I buy the latest edition of book? (the book I possess is probably ANSI C89 based)
And, also which ANSI C standard you follow-ANSI C89 or ANSI C99?

THANKS...........

============
AmbrNewlearner
============
Jun 13 '08 #3
JosAH
11,448 Expert 8TB
I only know of K&R2 (which predates C89 a bit) as the latest edition.

kind regards,

Jos
Jun 13 '08 #4
AmberJain
884 Expert 512MB
Can you please have a look at the picture/image of the book in the link below and confirm the book's latest edition----->


LINK

THANKS...........

============
AmbrNewlearner
============
Jun 13 '08 #5
JosAH
11,448 Expert 8TB
Yep, that K&R2 and it's the latest edition as far as I know.

kind regards,

Jos
Jun 13 '08 #6
Banfa
9,065 Expert Mod 8TB
I have that book, it's good. Also although C99 is the latest standard I think many C compilers (not all) only support C89 (or C90, C89 wasn't a ANSI standard I think C90 is the ANSI standard but is identical to C89 or some similar red tape mumbo jumbo).

I know many of the C compilers I use on micro-controllers are C89 compilers. I tend to find my self either using C89 or C++ depending on available toolset for the platform.

I have managed to successfully be a programmer for 20 years without owning a copy of the standard. Even when I became more concerned with writing standard compliant code a few of years ago I found owning the standard was not necessary, I just browsed the news group comp.lang.c and the faq pages produced by its members.
Jun 13 '08 #7
Atos
7
I think that there is no need for owing the ANSI C STANDARD except if you want to wrtite a compiler or some sort....
Besides, the standard is a struct document about the syntax of the language and so on....
I think that in K&R book somewhere ( or in another book i do not remember exactly ) states what i said above. If you wanna write a compiler take the standard, else not.
Jun 15 '08 #8
AmberJain
884 Expert 512MB
THANKS to JosAH, Banfa, Atos..............

============
AmbrNewlearner
============
Jun 15 '08 #9

Sign in to post your reply or Sign up for a free account.

Similar topics

24
by: David Mathog | last post by:
If this: int i,sum; int *array; for(sum=0, i=0; i<len; i++){ sum += array; } is converted to this (never mind why for the moment):
9
by: Tim Rentsch | last post by:
I have a question about what ANSI C allows/requires in a particular context related to 'volatile'. Consider the following: volatile int x; int x_remainder_arg( int y ){ return x % y; }
4
by: Luke Wu | last post by:
I am just wondering what the following terms usually mean: 1) "Standard C" 2) "K&R C" 3) "ANSI C" I am pretty sure "ANSI C" usually refers to the C89 standard, but what
4
by: Anonymousgoogledeja | last post by:
hi all, while I read the code from linux sources. I read the statement static const struct iw_ioctl_description standard_ioctl = { = { .header_type = IW_HEADER_TYPE_NULL, },
66
by: KimmoA | last post by:
Hey! Some questions about C that have been bugging me for a while... 1) Is inline a valid C keyword or not? I was kind of surprised of not finding it in C, to be honest. My "The C Programming...
127
by: bz800k | last post by:
Hi Does this code satisfy ANSI C syntax ? void function(void) { int a = 2; a = ({int c; c = a + 2;}); /* <<-- here !! */ printf("a=%d\n", a);
31
by: arun | last post by:
I know it is a free compiler. But does it follow any standard? If so which standard is it? (Ansi, Ecma, etc?)
9
by: andrew | last post by:
Hi: I use "g++ array.cpp" on freebsd, surprised, the code can be compiled #include <iostream> using namespace std; int getInt() { int a = 10; int b = 2; return a * b; }
56
by: nembo kid | last post by:
What do you think about the following book: C How to Program, 5/E (Harvey & Paul) Deitel & Associates, Inc. <http://www.pearsonhighered.com/educator/academic/product/0,3110,0132404168,00.html>...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.