Reddit Reddit reviews C Programming: A Modern Approach, 2nd Edition

We found 46 Reddit comments about C Programming: A Modern Approach, 2nd Edition. Here are the top ones, ranked by their Reddit score.

Computers & Technology
Books
Computer Software
C Programming: A Modern Approach, 2nd Edition
Check price on Amazon

46 Reddit comments about C Programming: A Modern Approach, 2nd Edition:

u/Idoiocracy · 38 pointsr/programming
u/kindofasickdick · 29 pointsr/programming

K.N. King's C programming
covers upto C99, I don't know if there's anything significant in C11.

u/cismalescumlord · 17 pointsr/learnprogramming

It's not cheap, but C Programming a modern approach is very good.

All you need to get started is a text editor and a compiler. Which ones they are depends on your platform.

u/Yawzheek · 17 pointsr/learnprogramming

C Programming: A Modern Approach is quite good, and before I go into detail, let's pause for a moment and discuss "The C Programming Language" by Dennis Ritchie.

It's incredibly good, provided you're an experienced programmer. It's incredibly bad otherwise. There's no doubt Ritchie knew his stuff (he did create the language), but from a learning perspective of a new programmer, you're going to be incredibly lost. Hell, I came from quite a bit of C++, and even after working with some C code it was quite confusing.

"A Modern Approach" is very much a book with which you can learn C, even as a beginner, but also doesn't treat you like an idiot. One thing it does quite well is it contains a "Q&A" section that covers common questions (or otherwise things you wish you had thought to ask) and is quite detailed, including some modestly challenging exercises. He posts the solutions to some of the challenges online as well.

It's not perfect, but I've never found the "perfect" book. The book is, however, thorough, reasonably easy to understand, and has a knack for knowing the mistakes rookies will undoubtedly make, as well as questions they probably have, which is surprisingly rare.

When it comes to programming books for the beginner, most fall into the category of:

  • "Cutesy" but teaches bad habits and doesn't cover enough, which is where I suspect "Head First" is firmly located based on my experience with their HTML series.

  • Advanced, which is where "The C Programming Language" firmly falls, despite what others may have you believe. Difficult if not impossible for the beginner to crack, but great coverage.

    King opted for an alternative route, in that it has great coverage, isn't too advanced, but also isn't cute either. He very much gets down to business, but has an understanding of his audience. My only fault? Again, some of the examples get somewhat complicated for the beginner, and he doesn't pause every so often to tell you to take a break from reading and give you a small task to try yourself.

    EDIT: Also, avoid "C: How to Program" by Dietel. Quite literally nearly half the book is just a crash course into C++. I've no idea how this ever made it past a publisher. Well, it's a Pearson book, so I have an idea, and it also helps explain the ridiculous-ass price. Put another way, for the cost of this one book, you could buy King's book and another book on C++ new, and still have money left over.
u/VampireCampfire · 15 pointsr/C_Programming

Either K&R's The C Programming Language which is often considered "The C Bible" and is written by the authors of C, or a more recently published C Programming: A Modern Approach are both excellent and comprehensive learning resources. I personally recommend the latter because I believe it is more relevant and includes almost, if not all, the information in K&R.

u/Bizkitgto · 13 pointsr/learnprogramming

I'd start with Harvard's CS50 on edx, it's the best course you'll find anywhere bar none. The instructor, Dave Malan is world class. The first half of the CS50 lectures are on C and on youtube. There's also r/cs50.

Also, the Richard Buckland lectures are all up in youtube as well, really good intro to C programming. People love this guy!

Here is the Aalto C Programming MOOC based on K&R.

You can learn C, all you need is a text editor (like notepad or sublime), and the terminal/command line. You don't need any internet connection whatsoever.

I recommend getting this book C Programming: A Modern Approach, it's great for beginner's, and you can try going though the examples. You can also try going through all the problem's in K&R's C Programming (what many refer to as 'The C Bible') book if you want to be a C Ninja.

Here is a guide on how to compile C programs on a Linux system.

You can find used copies or PDF's of these books online if you don't want to pay full price. I like having a hard copy in front of me when learning as I can flip back and fourth quickly.
Since you want to learn C - you should read K&R's The C Programming Language (the bible for C) at some point.

u/Nezteb · 11 pointsr/C_Programming

Some physical book recommendations:

u/inequity · 9 pointsr/gaming

That's awesome. My recommendation would then be to apply to the school, study the hell out of your mathematics, and start learning C. (I'd recommend getting familiar with Cygwin and GCC, reading C Programming by K.N. King and trying to work through this.)

Good luck!

u/[deleted] · 7 pointsr/programming

Learn C. Some good beginner books are Programming in C
and C Programming A Modern Approach

If you're really dedicated to learning with C++ first I would recommend Programming: Principles and Practice Using C++ its a great book for determined beginners, its not a C++ language manual instead it's a book on programming.

u/Wiggledan · 7 pointsr/C_Programming

I've been self-teaching myself C through various books/courses/series the last few months (I'm still not that great), and so I have some suggestions about good places to start learning.

Books:

  • The C Programming Language AKA "K&R" by developers of C - It's short/concise and simple, but covers the whole language (because there's not that much syntax to cover), and tons of people swear by it like a bible.
  • C Programming: A Modern Approach by K. N. King - This book is much larger and more in depth than K&R, with around 800 pages and lots of examples and exercises. It's essentially a college textbook and is actually used in colleges.
  • Learn C the Hard Way by Zed Shaw - This one is free and online. I like it because it focuses more on you figuring out things on your own by breaking the code in various ways and having an absolute understanding of every line, rather than just having you copy everything and telling you how it works

    Courses/Videos:

  • [Harvard CS50x](https://www.edx.org/course/introduction-computer-science-harvardx-cs50x) - An awesome, free online course with high production lectures, and helpful videos/tips if you get stuck. It mostly covers C, but it does go into other things (that are still worth knowing) at the very beginning and end.

  • A Free Course for C Beginners by Carl Herold - Not really a full course, just most of the videos. I found this very recently, and the original website doesn't exist anymore. It goes at a very relaxed pace and explains things incredibly well in a way that you will remember. These videos really solidified/helped my understanding of binary, hex, and pointers. I highly, highly recommend it over anything else if you're just starting out.
  • Handmade Hero by Casey Muratori - You can watch and follow along with this guy as he programs a video game from scratch in C. He streams every weekday, usually has a Q&A after, and puts every video up on YouTube. The series starts off with a sort of rushed intro to C, and honestly the whole thing is always at a fast pace and can feel complicated. But that's what it takes to make a game from scratch, and he takes time to explain what everything means. Plus it's mostly all very interesting and useful.

    Resources:

  • Google - google everything, or Bing it, I don't care
  • Stackoverflow - someone probably asked your question before, especially with C
  • /r/dailyprogrammer - Great daily challenges. These are like working out your programming muscles.
  • /r/learnprogramming - Occasional posts about C, and you can ask/find your questions here as well
  • Online C Compiler - A convenient compiler that you can use anywhere to play with simple programs using C standard library functions.

    Other than that, you should maybe look into trying out Linux, because it's more developer-friendly than Windows (such as having a C compiler out of the box). And the whole kernel and many core components of the OS are written in C, which are all usually open source, so you can learn from, and contribute to them.

    Good luck, friend.
u/shvr · 7 pointsr/C_Programming

Read C Programming: A Modern Approach by KN King. It's one of the best introductory C books available.

u/softwaredev · 6 pointsr/ECE

On top of what any other comment recommends here I also recommend that you learn C very well (structures, unions, pointers, bitwise operations, static, extern, volatile, etc)

This is my favorite C book
http://www.amazon.com/C-Programming-Modern-Approach-2nd/dp/0393979504/ref=sr_1_1?ie=UTF8&qid=1415412105&sr=8-1&keywords=modern+C

also read or skim over the manual of whatever compiler you choose, you will sometimes be stuck and remember that your specific compiler's features offer the solution to your problem.

u/spilled_water · 6 pointsr/C_Programming

You would love C Programming: A Modern Approach.

The book gets into some pretty advanced stuff. From MAKE files, to programming idioms, to how to organize your code.

It's a really dense book, but super well organized, super clear for almost all topics (only two or three topics I needed to google), and most importantly very thorough.

I was reading the book to refreshen my C. Out of curiosity, I looked up common or important interview questions on embedded C, and pretty much the book nailed it down.

u/terminus1256 · 5 pointsr/EngineeringStudents

I'd recommend learning Python. It's really simple to transition to for someone who knows MATLAB and it's really useful.

The official Python tutorial here is good: https://docs.python.org/3/

Python 2 is definitely more widely used right now, but Python 3 is the future of the language, so I'd go with learning 3 if I were you.

C is good to learn, you can either try Kernighan and Ritchie (the "bible of C", actually written by the creators of the language), but I hated learning from that book. I picked up this book and it was fantastic. Most online C resources suck ass.

u/Mansaber · 5 pointsr/C_Programming

The gold standard for a newbie that wants to learn C99 is K.N. King's "C Programming: A Modern Approach".

u/reddilada · 3 pointsr/learnprogramming

C Programming: A Modern Approach gets a lot of good reviews.

I learned from K&R. LCTHW has a bit of drama associated with it. This thread has a bit of discussion regarding the book.

Also, check out the /r/c_programming reddit.

u/_lyr3 · 3 pointsr/C_Programming

C and C++ are totally different programming languages.
------------------


  1. Code Blocks, Eclipse...

  2. Get a good book as: K&R, C modern approach or C reference manual

  3. Books exercises, open source projects
u/vinlinux · 3 pointsr/C_Programming

These are my standard recommendations to anyone who wants to learn the C language these days:

https://www.amazon.com/C-Programming-Modern-Approach-2nd/dp/0393979504/ref=sr_1_1?ie=UTF8&qid=1537025256&sr=8-1&keywords=king+c+language&dpID=41%252BbFKtFHjL&preST=_SX218_BO1,204,203,200_QL40_&dpSrc=srch

https://www.amazon.com/Reference-Manual-Samuel-P-Harbison/dp/013089592X/ref=sr_1_sc_1?ie=UTF8&qid=1537025419&sr=8-1-spell&keywords=herbison+steele

The first one is a great book to learn C from the basics to the details of the standard library, and it's updated to cover the C99 Standard. The second is more of a reference that is very useful once you get more experienced, it covers C99 as well, it is basically the C Standard document rewritten for humans : ) My students find the first one very complete and full of good exercises and explanations. Not everyone has bought the second, those who have find it invaluable.

u/CodyChan · 3 pointsr/C_Programming

Agreed, C Programming A Modern Approach, 2dn edition is the textbook I would recommend if you want to learn C, K&R is classic , but it lacks a lot details in C which are coverd in books like Pointers on C and C Traps and Pitfalls, C Programming A Modern Approach, 2dn edition covers most, if not all, of them.

u/pythonaut · 2 pointsr/learnprogramming

I recently bought C Programming: A Modern Approach, and it has been fantastic. It has a lot of exercises in each section, and an extremely helpful Q&A section for each chapter that clarifies a lot of common problems. It's easily the best programming book I've dealt with so far, though really I've only been through four or so.

u/dsampson92 · 2 pointsr/AskElectronics

>2. If it's not too difficult and something that could be learned over a few months (minus full time work), what sort of subjects, books, pdfs, wikis or other resources would I need to be looking at to get started? I'm a web designer so this isn't really my field... but if there's a specific area of electronics that covers this sort of project, it'd really help to find out.

It is too difficult to do in a few months, but if you are really interested in learning, follow the curriculum of an Electrical Engineering BS. First you need to know calculus, this would be a good place to start, get the used version of course. Alternatively, watch the Khan Academy videos for calculus and find some problems to practice, though this will be less thorough.

Once you have gotten to integrals, start your calculus-based physics education. There is no point in really starting before, as algebra based physics isn't terribly useful for actually understanding things, and you will have to relearn it all with calculus anyways. Halliday and Resnick is a fairly good intro text that includes calculus. The one I linked is just the E&M sections, you can learn the mechanics stuff from Khan -- you just need a cursory understanding of the mechanics. Unfortunately the Khan videos aren't very good for E&M, they are generally too algebra-based. Last I checked he doesn't even cover Gauss's law.

After that you will need some Linear Algebra, Differential Equations, Digital Logic, Circuits, and programming just to round out your fundamentals. Now you are roughly 2 years into a basic ECE curriculum, ignoring a lot of filler courses as necessary.

After this it gets a bit more flexible.

Textbooks on Signals and Systems, Microcontrollers/Microcomputers, Antenna Design, Embedded Devices, Electric Networks, and Digital System Design should round out your education. However that doesn't mean you know what you need to design what you are thinking of -- you also need to get a bunch of real world knowledge and practice. Make a few basic devices, get them manufactured, just to get a feel for the process. Delve into the various IEEE standards and UL standards to learn what you need to do to produce a device that can be sold and will be compatible. You have a lot of research ahead of you, so good luck!

u/shinigamiyuk · 2 pointsr/cscareerquestions

Agree. Change your degree and focus on CIS or CS even for the AA. You could still get an AA in CS and transfer to a 4 years school and only have two years left.

For reading like ender08 said you need to know if it is java, or c++ track, but I would still read C Programming: A Modern Approach, this book is amazing. Take notes, and type out each example in either an IDE or text editor.

u/Broinz · 2 pointsr/C_Programming

I too started with C as my first language using K&R and "learn C the hard way" but i abandoned both halfway. I've started from beginning with "A modern approach to C" as my main source and C: A Reference Manual as, well reference manual when i wanted more in depth knowledge about particular subject. After you're done with Modern approach you should go back to K&R and finish it in order to have your foundation properly rounded.

Edit: I should add few more resources that generally helped me a lot when I started:

http://c-faq.com/

C Traps and Pitfalls

C Standard Library

Things you should avoid in C

A Guide to Undefined Behavior in C and C++

u/youngoli · 2 pointsr/learnprogramming

As everyone said, start with a book. C++ has a lot of cool features and a lot of really advanced things can be done with it, but before you start with any of that you're gonna need to learn the basics. It took me a year to understand most of the "basic" C++ concepts, so don't expect to have the quick learning curve that you would get in Python/JS.

However, I also strongly recommend you start by learning C before C++. I feel that C++ has too many advanced features wrapped around C, and you get into that confusing situation where a lot of C++ expects you to know how the low-level stuff works (especially memory allocation), while at the same time hiding it so much that you probably won't learn it. I suggest picking up some highly rated book on C and learning everything until you at least know how pointers and dynamic memory allocation work. Then you're free to go crazy with the C++.

PS: I recommend this book:
http://www.amazon.com/C-Programming-Modern-Approach-2nd/dp/0393979504/

u/jantari · 2 pointsr/sysadmin

Buy 2-3 good books on the C programming language and get really good with it. I personally read this one and liked it but it's not introductory in my opinion so start simple.

For system administration good python, bash and a surface-level understanding of C are enough

u/pushme2 · 2 pointsr/learnprogramming

To be honest, I would suggest some other book first (kochan and king are good enough), then reference/read that book if you have problems or just want to say you read it.

K&R is old, and while still mostly accurate, and can teach you C, there are books that are better suited for teaching people learning C in this century. One thing that the newer books lack usually is explaining old stuff. For example, many books don't sufficiently explain how the input and output buffer works.

I do think it's a good idea for people actually doing stuff with C to eventually read K&R, but starting from the basics, you might want a gentler approach.

u/Bifrons · 2 pointsr/learnprogramming

I used an earlier version of this in my first C programming class: http://www.amazon.com/C-Programming-Modern-Approach-2nd/dp/0393979504/ref=sr_1_1?ie=UTF8&qid=1311251965&sr=8-1

It was ok, but I find myself referring to the K&R book more on projects. It's just better in every way. Not that the first book was bad by any means.

I don't know if this is good, but here's a free book: http://beej.us/guide/bgc/ It's by the same guy who did the Beej's guide to Network Programming (http://beej.us/guide/bgnet/), which I highly recommend if you want to get into network programming at any point. This book was instrumental in me passing my network programming class.

Second, don't use an IDE like Eclipse. Use a text editor (my preference is VIM) and GCC. You'll learn more. Once you get the basics down, then learn an IDE.

Finally, as Madsy9 pointed out, look into revision control (Git, Subversion, CVS, etc) at some point. However, I would learn a bit about the language first before using revision control. In my CS curriculum, we didn't touch revision control until Operating Systems in my third year. Previously, we learned C and simple data structures (linked lists and the like) before touching revision control. Then again, CS != Software Engineering, so I could have been taught completely wrong on this.

u/sidcool1234 · 2 pointsr/technology

I suggest this book

u/sastrone · 2 pointsr/java

Hey, I'm also learning C as well. I have spent the last 4 years with Java and wanted something more lower level.

I picked up a copy of C Programming A Modern Approach and have been completing one chapter a night. And by one chapter a night, I mean reading the chapter, taking notes on stuff that I don't get, and doing all of the programming projects. Even the early chapters that are super easy, I figure that it will help me learn the syntax so that I'm not screwed later.

If you have the time to learn slowly like me, I really suggest it.



As for practicing C online, as far as I know, that is impossible. C is way too destructive to allow people to compile and run it on some server.

u/xSinxify · 2 pointsr/HowToHack

Both posts here (so far) give good advice in terms of learning assembly. I personally used the OpenSecurityTraining course that was linked by /u/miguelhgn to fill in gaps I had in assembly, and I second his advice to check that one out. If that course proves to be too steep, I'd take a step back and learn a bit of C -- so that you can better understand the context of the assembly you would be reading. For free resources, I generally like to recommend https://publications.gbdirect.co.uk//c_book/ or http://users.cs.cf.ac.uk/Dave.Marshall/C/ as they're iso-9899 recommend free resources that cover a pretty good scope when it comes to C itself.

If you'd prefer a more textbook style of reading, and don't mind shelling out money, I generally recommend C Programming: A Modern Approach above anything else that's out there, but it's far from necessary to get this if you find that you learn from the free resources just fine.

As for recognizing patterns in assembly over time as mentioned by /u/poindexter_one, that would best be implemented by using https://godbolt.org/ imo, and starting with smaller C snippets, trying different compilers and optimization levels, and gradually doing the same with more complex code. A good exercise when you start to get good at that, is to also try to do the same thing in the opposite direction (Seeing assembly, and trying to construct C code from it, AKA a part of reverse engineering)

As for your question "Should I learn Assembly language?" depends on where your interests lie, and what you eventually want to learn / be able to do down the line. It's absolutely a good thing to be able to understand though.

u/gnuvince · 1 pointr/programming

I have to say that I don't know. I know that some people like KNK, but as I haven't read it, I cannot vouch for it.

u/avinassh · 1 pointr/india

Exact book name is C Programming, A Modern Approach. And get the second edition. (amazon link for reference)

u/hugthemachines · 1 pointr/AskProgramming

I checked out a discussion about K&R the other day. Eventhough it is a classic in programming litterature, it seems like it is a good idea to pick an other book for starting to learn C for you.
The recommendation I found was C programming, a modern approach. Here is an example link. https://www.amazon.com/C-Programming-Modern-Approach-2nd/dp/0393979504

u/lol_te_dolio · 1 pointr/TechoBlanco

Por lo menos no es Asm.

Dicen que este esta pro, igual lo adquiero cuando acabe el lcthw.
http://www.amazon.com/Programming-Modern-Approach-2nd-Edition/dp/0393979504/ref=pd_sxp_grid_pt_0_2

u/Adams_Apples · 1 pointr/learnprogramming

My recommendation is that you learn the C programming language well before attempting to learn Objective-C. There are tons of online and text resources for learning, the one most used by university C programming courses is this text:

http://www.amazon.com/Programming-Modern-Approach-2nd-Edition/dp/0393979504/ref=dp_ob_title_bk

Ideally you should get a copy of this or another good learning text, but again, if money is an issue there are resources online for learning.

Here's a good site with lots of videos: http://www.lynda.com/default.aspx
Also this: https://www.udemy.com/c-programming-for-beginners/

And there are resources online that are totally free as well, although they aren't typically as comprehensive and may require a bit more initiative on your part, a quick google search will give you several examples.

With all that said, I'll go ahead and answer your questions, with the understanding that if you just try to dive right into Objective-C it might not work so great for you. This is going to be over your head, so don't get discouraged by it, just remember, we all started somewhere, good luck learning programming!

> 1.) What is a property?

A property is an attribute that the system automatically creates standard accessors (methods to get an attribute) and mutators (methods to change an attribute). Properties also allow you to specify atomicity (a specifier that guarantees thread safety at a small performance cost) as well as reference strength (strong adds 1 to reference count, weak does not). There is more to them than this, this is just a brief overview answer.

> 2.) Why do you need both a public and private API? How do you determine what goes in which?

Public simply means things that you want exposed outside of a class, whereas private are things that only the class should see. By doing this, you can convey to programmers who use your class how the class should be used, as well as restrict access only to attributes that the user of the class needs. This concept is called encapsulation, and is a key concept in object-oriented programming.

> 3.) What is an argument?

An argument is a variable or object that the calling function supplies to the called function. It is the primary means of passing information from one function to another function.

> 4.) What is a heap and a stack? What does it mean when objects "live in the heap"? (Do they live in condos? Is it a quaint suburban community?)

The heap is a block of memory that can be allocated as a program is running. In Objective-C, all objects reside on the heap, because of the way the Objective-C runtime works. In contrast, the stack is statically (compile-time) allocated memory. Primitive types such as int or char are statically allocated.

> 5.) So classes are the .h and .m files in Xcode?

The files with the .h extension contain the interface of a class, which is the file that other classes using this class import. The files with the .m extension contain the implementation of a class, which is where the details of how a class's methods are outlined. This separation exists to simplify linking of files when a program is compiled, as well as to facilitate precompiled libraries (where only the header is visible as source, the implementation is provided as a binary).

> 6.) What do all the differet colored text in Xcode mean?

In Xcode, go to Xcode > Preferences > Fonts & Colors

> 7.) Why are some things capitalized and others are not in Objective C code?

As you learn programming, you'll learn that good programmers adhere to conventions when writing code. The specific reasons why things are named the way they are will come to you as you learn, just bear in mind that good code that follows recommended guidelines is easier for other programmers to work with, your colleagues will thank you for doing it right!

u/Petross404 · 1 pointr/C_Programming

IMHO if you can afford the C Programming: A modern Approach (2nd Edition) , then go for it by all means. Read the customers reviews to see why.

u/phao · 1 pointr/learnprogramming

I've read good things about this one:

https://www.amazon.com/C-Programming-Modern-Approach-2nd/dp/0393979504/

I've learned C mostly from this one:

https://www.amazon.com/Programming-Language-Brian-W-Kernighan/dp/0131103628/

I think both are good. I imagine the first one has more examples and exercises. Although I find it difficult that it'll be more interesting than the second one.

u/qwerty_danny · 1 pointr/learnprogramming

Try C programming: A modern approach K&R is the classic, but it only covers up to the ANSI C (C89) standard.

u/KopixKat · 0 pointsr/learnprogramming