Path: csiph.com!eternal-september.org!feeder.eternal-september.org!reader02.eternal-september.org!.POSTED!not-for-mail From: Keith Thompson Newsgroups: comp.lang.c Subject: Re: What platform is targeted in the C books? Date: Fri, 01 Dec 2017 08:58:01 -0800 Organization: None to speak of Lines: 28 Message-ID: References: <5a1a4985$0$1751$b1db1813$764c84@news.astraweb.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: reader02.eternal-september.org; posting-host="ccf519c238b83d58af35e4f4ed341a14"; logging-data="16868"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18LL/SJhXmUIJLbuINzn0xL" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) Cancel-Lock: sha1:Lwc7YnRYk9oLAqc2fNXEK9wMN20= sha1:BI55mW3qFHkOoL0Gm+5Bz/2wCpY= Xref: csiph.com comp.lang.c:123678 John Bode writes: > On Saturday, November 25, 2017 at 10:56:56 PM UTC-6, Elof Huang wrote: >> I know there are lots of good c programing books, but don't know if the >> codes showed on the books are suitable for all platform? Windows? Linux? >> BSD? > Books by K&R, Harbison & Steele, Deitel & Deitel, and King should > be platform-agnostic - their examples shouldn't require the > presence of platform-specific headers or system calls, and their > examples should work anywhere you have a (conforming) C compiler. > Note that this means all their examples are command-line driven, > so they *do* assume you have some kind of command-line shell > available (bash, CMD, etc.). > There *are* books that target specific environments (such as > how to do multi-threaded programming on Windows, or networking > code on *nix, or GUI programming on Macs), but general-purpose > C language references, as a rule, don't. I'll note that K&R (both editions) has a section that covers the UNIX system interface, but it's reasonably well separated from the rest of the book. -- Keith Thompson (The_Other_Keith) kst-u@mib.org Working, but not speaking, for JetHead Development, Inc. "We must do something. This is something. Therefore, we must do this." -- Antony Jay and Jonathan Lynn, "Yes Minister"