Learn C/C++
And want to learn how to program in C/C++, and later I want to use it to create some simple GTK apps. I guess C is the best language then?
Is there any good online books/tutorials that I can start with? |
GTK programming in C is very complex for a beginning programmer. I would highly recommend you learn C for longer than you think you should before moving into GUI programming. I have the book "The Official Gnome 2 Developers Guide", let me take a quote from the Introduction chapter:
Quote:
As for which C book to buy, I started with C++ and moved back to C, so I'm the wrong person to ask on where to start learning C. I started learning C++ from the book 'C++ Primer Plus: 4th Edition' by Stephen Prata, and I know he has written the same book for C as well. I really liked the book and still reference it every once in a while. As your skills progress, you'll want to pick up 'The C Programming Language' by Kernighan and Ritchie. Good luck, - lowpro2k3 |
The ultimate C book: "The C Programming Language, Second Edition" Kernighan and Ritchie prentice Hall
Tutor: www.its.strath.ac.uk/courses/c/ THE ultimate C++ tutorial: www.cplusplus.com/doc/tutorial/ Hope it helped! :) |
Quote:
i started learning a year ago then started just recently relearning things and having a better understanding now then i did back then. I have tried gtk programming and after creating a program with 2 buttons decided i better learn more about C before trying anything further. gtk is eazier then i would say xlib is but can still be very confusing to a new programmer like myslef. |
Thanks for your replies. I have actually considered to buy "The ultimate C book: "The C Programming Language, Second Edition" Kernighan and Ritchie", and I think I will buy it now.
So, the right thing to do for me if I want to learn to program simple GTK apps is to first learn C, and then learn GTK? And yes, I'm prepared to spend some time learning C first. |
How much programming experience do you have? I dont think 'The C Programming Language' is suitable for non-programmers. I think you would just end up getting frustrated at TCPL, you should look for more of a beginners book instead, just my two cents.
|
To master GTK it requires quite good C knowledge (especially things like pointers). There are tutorials, however, that start with very simple examples, so you can check them just after 2-3 days with C. The time may vary depending on the fact if you know any programming language (learning 2nd, 3rd... is much easier than first) or not.
|
Well, I don't have much experience. I do know PHP very well...
Do you have any beginners-books to recommend? |
I'm really a fan of the '[insert language] Primer Plus' books. You could try 'C Primer Plus' by Stephen Prata.
http://www.amazon.com/exec/obidos/tg...books&n=507846 |
Hi
my two cents..okay more like 30 cents.. I have been programming for just over a year and am still very much on the learning curve. However I feel that I have enough experience to lend you a valid opinion. My first introduction to C was through K&R mentioned above. B4 that; my only other programming experience was some basic college assembly language anyway.. I have a couple of other books on C but the beauty of The C Programming Language, Second Edition" Kernighan and Ritchie prentice Hall is that it gives a feel for the fundermentals of the language and how to approach a C program very early on. Unlike other books that give you pages and pages of syntax on basic functions .Details which IMHo you are better off picking up as you go on ?!?! I also don't feel that C is too hard as a first language.All though I do concede that it takes some mastering(I'll lket you know wen I have),but you can have fun writing useful unix/linux programs on the way. i think you may wish to humble your ambitions slighty at first ,but you WILL get there if it is what u want to do. ta. slzckboy. |
I highly recommend this book to start learning C: http://www.amazon.com/exec/obidos/tg...82263?v=glance
It's less terse than K&R. K&R is fine as a reference once you know the basics of C. |
HI!
Well, also, depending on your priorities, you can program for GTK using languages which are supposed to be simpler, like Python. I wouldn't be surprised if there are PHP binding for GTK! In that way you will be learning a lot about GTK. On the other hand, if your priority is C, then a good book (like those that have been posted) and the many tutorials on the internet will suffice. HTH! |
I found Ivor Hortons book, Beginning C (Third Edition) very helpful. Though I moved on to his ANSI C++ rather than move to GTK+.
|
Quote:
|
Quote:
|
All times are GMT -5. The time now is 07:21 AM. |