As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
I'm trying to learn how to program in C. As C is similar to C++ I don't have any problems learning the basic commands (like for, while, do, variable declaring, preprocessor directives, etc). But I find it hard to understand C's libraries. Does anyone know any tutorials about C libraries with code examples?
Dennis M. Ritchie, Brian W. Kernighan - "The C programming language".
Related
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
I have to write Tower Defense game in ANSI C using SDL library, but the deeper I go into LazyFoo's tutorial, the more I got this feeling that's impossible to write it in pure C due to limitations. So my questions is - am I in big trouble or I'm just panicking. It has to be a simple tower defense game, nothing fancy, but is it possible to do it using only C?
C is a Turing-complete language so anything you can do in some other language can be done in C, too. And SDL provides you with a graphics API which is commonly used for (usually small/indie) games.
Of course it might be more pleasant to write it e.g. in C++ or a higher-level language such as C# or Python - but it's possible in C nonetheless.
TL;DR: Yes, it is totally possible.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
I am a PHP developer, and now I want to learn C for a couple of reasons.
I lack knowledge in Java, as well as data structures and algorithms.
PHP is written in C.
The most important thing is the first reason. I don't want to get deep into C, but at least I could understand what C programs are doing. Does anyone have any good idea how I should proceed? Thanks!
That's probably the wrong approach. First learn the basic theory behind programming which is algorithms and datastructures. These are language neutral.
Than try to learn a language and its syntax to write your algorithms. To answer your question, a good book for C is C in a Nutshell but it DOES NOT teach you the basics of programming.
And then there is still the book The C Programming Language by Kernighan&Ritchie, who invented C.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
I know that I can write CGI in many languages, the most are C and Perl.
But why I have to write it in Perl or in C?
What's the difference and what's the (eventually) the best and safe solution?
The advantage of nearly all dynamic languages over C is that it's much harder to get buffer overflows while doing string manipulation, which can easily become a security problem.
Also Perl has libraries that help you dealing with the CGI protocol, and they are battle tested and stable.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 11 years ago.
I just finished a college course in C. The book used was Kochan's. I am tempted to now tackle K&R to deepen my understanding of the language. Theoretically I should already know all the material in it, but I still feel like I would benefit from going through it including doing the exercises.
Any thoughts or feedback?
Thanks.
+1 for reading it. It's a brilliant, concise book, brilliantly written.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 11 years ago.
I need to introduce basic design principles in my team. I am looking for books which are not restricted to only object oriented design principles. And which can cover concepts such as Modularity, Information hiding etc.
Just for information - The implementation language for all the project in our team is C.
These books seem to be in the vicinity of what you are asking about:
Code Complete
The Practice of Programming
The Pragmatic Programmer
If you're building on a Unix environment, I'd really recommend The Art of Unix Programming by Eric S Raymond.
The book
Object Thinking by David West is pretty good.