• RSS
  • Twitter
  • FaceBook

Security Forums

Log in

FAQ | Search | Usergroups | Profile | Register | RSS | Posting Guidelines | Recent Posts

C Programming

Users browsing this topic:0 Security Fans, 0 Stealth Security Fans
Registered Security Fans: None
Goto page 1, 2  Next
Post new topic   Reply to topic   Printer-friendly version    Networking/Security Forums Index -> Programming and More

View previous topic :: View next topic  
Author Message
TheDrunkenMaster
Just Arrived
Just Arrived


Joined: 09 May 2004
Posts: 0


Offline

PostPosted: Thu May 13, 2004 10:28 pm    Post subject: C Programming Reply with quote

I was told that if i wanted to master several languages, i have to learn the most basic and raw one out there, C. Now i've tried googling for the tutorial and only found a couple of tutorials, but nothing that has satisfied me yet... So if anyone that might have one or has a link to a really good C tutorial, i would surely appreciate the help.

Thanks. Twisted Evil
Back to top
View user's profile Send private message
Stormhawk
Trusted SF Member
Trusted SF Member


Joined: 26 Aug 2003
Posts: 31
Location: Warwickshire, England, UK

Offline

PostPosted: Thu May 13, 2004 11:00 pm    Post subject: Reply with quote

Forget a tutorial... buy this book:

The C Programming Language, 2nd Edition
Brian W. Kernighan & Dennis M. Ritchie
ISBN: 0-13-110362-8

It is generally considered the definitive C Programming book, 'The K&R Book'. Trust me, you won't need any other C book!
Back to top
View user's profile Send private message Visit poster's website
UziMonkey
SF Reviewer
SF Reviewer


Joined: 19 Dec 2003
Posts: 5


Offline

PostPosted: Thu May 13, 2004 11:23 pm    Post subject: Reply with quote

If you're new to programming, the K&R book will probably seem overly terse and hard to understand. There's no need to start with C, it's more practical to start higher and move to lower-level languages as your skills and understanding progress. This may seem backwards, and it probably is. If you're not understanding C, come back to it, there's no point in making other necessary skills suffer, which can be taught with easier to learn and more forgiving programming languages.
Back to top
View user's profile Send private message Visit poster's website
Whitetoque
Just Arrived
Just Arrived


Joined: 23 Apr 2004
Posts: 0
Location: Canada's National Capital Region

Offline

PostPosted: Thu May 13, 2004 11:41 pm    Post subject: Reply with quote

I can recommend another publication if you're interested in learning introductory C - Sams' "Teach Yourself C in 21 Days". Whilst I'll admit that I am not a master when it comes to programming, this is the book got my feet wet.

Used book stores usually have a copy or two, so if you look around you'll probably be able to come up with a used copy on the cheap. I've included a URI below that will take you to the publisher's website and the latest incarnation of the book.

Cheers,

Ted

Ted Mac Daibhidh, CD
Network Intrusion Detection Specialist

E-mail: ubergeek(at)whitetoque(dot)ca
URI: www.whitetoque.ca/ubergeek
Public PGP key is available at www.whitetoque.ca/ubergeek/pgp.htm


============================================

"Teach Yourself the C# Language in 21 Days"

http://www.samspublishing.com/title/0672325462
Back to top
View user's profile Send private message
capi
SF Senior Mod
SF Senior Mod


Joined: 21 Sep 2003
Posts: 16777097
Location: Portugal

Offline

PostPosted: Fri May 14, 2004 1:20 am    Post subject: Reply with quote

UziMonkey wrote:
If you're new to programming, the K&R book will probably seem overly terse and hard to understand. There's no need to start with C, it's more practical to start higher and move to lower-level languages as your skills and understanding progress. This may seem backwards, and it probably is. If you're not understanding C, come back to it, there's no point in making other necessary skills suffer, which can be taught with easier to learn and more forgiving programming languages.

Ok, I do agree with that to a certain extent. Starting off with something simpler will let you achieve tangible results in less time and help to keep you motivated towards learning more. It all depends on the type of learner you are. If you prefer taking things slowly and not diving head-on than I'd recommend starting with something simple as Scheme (a derivative of LISP, good toy learning language), or if you're looking for a quick start on GUI stuff, you might try Visual Basic (provided you don't get too used to it, VB is about as useful and representative of programming languages as a stone is of contemporary music). Whatever you do, don't make the mistake of starting with Object Oriented crap such as Java or C++, you will end up a lot more confused than you should be and it will insert a lot of artificial vices into your mind which will make it harder for you to later adapt to other languages.

Nevertheless, if you're really interested in coding, it's very much important to learn C - to borrow from and paraphrase cisco student's signature: When you understand C, you will understand the world. When you understand Java... you will understand Java. It's just important to know good C, wether it be early on in your studies (which would be my recommendation to make sure you don't get hooked on small comodities some languages may provide that may not exist in other languages) or later on. It's just that - as in everything - if you really want to understand coding, you have to understand how things work under the hood, not just settle for what's already layed out for you. For that C is great, only topped by assembly (which would indeed be a way too demanding starting block for an inexperienced programmer).

It all comes down to your personal preference and method of study: if you prefer starting with something simpler, "dumbed down" so to speak, where you don't have to worry about the details and just get things going, I'd recommend VB or Scheme. The latter is not a popular language but it's simplistic view towards programming really helps to better understand the concepts by the novice coder. However, as much as I hate VB as a language, I must admit it's way of thinking is a lot closer to normal Windows programming than that of Scheme (which is more LISP-oriented, AI stuff), and as such may probably be a better starting place - provided you don't hold on to it for too long, it's just too far removed from any real use. If you prefer getting down and dirty, learning things by the base, getting good foundations then building your way up, I'd recommend by all means starting with C.
Back to top
View user's profile Send private message
UziMonkey
SF Reviewer
SF Reviewer


Joined: 19 Dec 2003
Posts: 5


Offline

PostPosted: Fri May 14, 2004 1:26 am    Post subject: Reply with quote

Whitetoque wrote:
I can recommend another publication if you're interested in learning introductory C - Sams' "Teach Yourself C in 21 Days". Whilst I'll admit that I am not a master when it comes to programming, this is the book got my feet wet.


I had to read this a few times to make sure it wasn't a joke.. A vast majority of these 21 days or 24 hours or "for dummies" books aren't worth the paper they're printed on. They're also so filled with errors, you'll spend more time trying to figure out where they made a mistake instead of figuring out your own mistakes. On top of that, most of them miss the point entirely, giving you NO background knowledge at all, simply telling you what to type to achieve a desired result.. I've seen better quality in Internet tutorials you can get for free, skip these books (take a close look at any SAMS book before you buy it, much of what they publish is utter garbage). Many people who learn from these books often discover that they didn't learn anything at all since they don't understand a single line of code, only the cookie-cutter BS they feed to you in these books.

There are good books though, and plenty of them. When starting a language, always look for books written by the creator(s) of the language. The K&R book is a good example, so is the C++ Programming Language and Programming Perl. Also pay attention to the publisher. SAMS mostly publishes cheap, watered down and completely unedited crap, most of their books won't be worth the money. O'Reilly books, on the other hand, are almost always good, I can't recall ever reading a bad one. Don't buy the first book you see (or the first book reccomended to you) without asking for advice or taking a close look at it, chances are you'll end up wasting your money..
Back to top
View user's profile Send private message Visit poster's website
alt.don
SF Boss
SF Boss


Joined: 04 Mar 2003
Posts: 16777080


Offline

PostPosted: Fri May 14, 2004 3:21 am    Post subject: Reply with quote

UziMonkey wrote:
I had to read this a few times to make sure it wasn't a joke..


To me it all comes down to whatever works for that individual. I personally did not find the K&R book that useful for a newbie to C. Whitetoque believes that the SAMS book is good. I have no problem with that statement as it obviously benefited him and that is all that matters. Learning is a very personal/subjective exercise. The key is in finding what works for you. Whether that be the K&R book, or SAMS as an intro to C. To deride such a statement as finding SAMS useful is not fair and smacks of coding arrogance imho. No sleight intended, but merely an observation.
Back to top
View user's profile Send private message Visit poster's website
hazmat
Just Arrived
Just Arrived


Joined: 25 Apr 2004
Posts: 0


Offline

PostPosted: Fri May 14, 2004 4:14 am    Post subject: Reply with quote

Just to give my two cents..

A long time ago, when I was a young man, my father made me learn Latin, in his words "It is the foundation of most contemporary languages."

He was right, my language skills improved considerably, and I thank him for it.

When my children ask me which computer language to learn, I'll tell them " Learn C, it's the foundation of most contemporary computer languages."

Hopefully it'll still be around, that way they won't be saying " Ahh Dad... C? That's so 1900s".

-h
Back to top
View user's profile Send private message
netRealm
Just Arrived
Just Arrived


Joined: 06 Feb 2004
Posts: 0


Offline

PostPosted: Fri May 14, 2004 4:23 am    Post subject: Reply with quote

Good thought hazmat!

TheDrunkenMaster:All I can recommend is the book I'm using right now: C Programming: A Modern Approach by K. N. King. So far I'm in chapter 4 (read I haven't spent much time on it Wink ). It is very straightforward, and easy to understand. Like was mentioned before, this is just my opinion and is all I'm familar with.
Back to top
View user's profile Send private message
Bhodi
Just Arrived
Just Arrived


Joined: 05 Sep 2003
Posts: 0
Location: Netherlands

Offline

PostPosted: Fri May 14, 2004 9:01 am    Post subject: Reply with quote

alt.don wrote:

To me it all comes down to whatever works for that individual.....


Agree! It's not what the rest of the world thinks is a good way/book to learn/master something, it's something personal.

My thoughts on the Keringan/Ritchie book. I think it's a pretty good book but not an easy one if you haven't got any programming experience. I also read the O'Reilly C book wich I found very easy to read, might wanna give that a chance.
Back to top
View user's profile Send private message
nickkrym
Just Arrived
Just Arrived


Joined: 14 Jun 2003
Posts: 0


Offline

PostPosted: Sat May 15, 2004 12:40 pm    Post subject: Reply with quote

To get back to the topic, here is a great C tutorial that I learned from. I recommend it to newbies as a great way to learn C.

http://www.iota-six.co.uk/c/default.asp
Back to top
View user's profile Send private message
UziMonkey
SF Reviewer
SF Reviewer


Joined: 19 Dec 2003
Posts: 5


Offline

PostPosted: Sat May 15, 2004 7:05 pm    Post subject: Reply with quote

alt.don wrote:
To me it all comes down to whatever works for that individual. I personally did not find the K&R book that useful for a newbie to C. Whitetoque believes that the SAMS book is good.


Yes, I do realize that, but it angers me to see people go out and waste money on books they later regret because one person said they liked it. That post kind of turned into a rant.. Can you tell that I don't like SAMS books? Wink
Back to top
View user's profile Send private message Visit poster's website
alt.don
SF Boss
SF Boss


Joined: 04 Mar 2003
Posts: 16777080


Offline

PostPosted: Sat May 15, 2004 9:05 pm    Post subject: Reply with quote

I agree with you uzimonkey. That being said though the SAMS book is clearly labelled as a howto in 21 days I believe it is. If people don't realize it is only meant as a cursory intro then that is entirely their problem. Indeed books do vary in quality but the SAMS does contain some useful info to the newcomer to C.

Cheers


Last edited by alt.don on Sun May 16, 2004 3:08 pm; edited 1 time in total
Back to top
View user's profile Send private message Visit poster's website
Bhodi
Just Arrived
Just Arrived


Joined: 05 Sep 2003
Posts: 0
Location: Netherlands

Offline

PostPosted: Sun May 16, 2004 9:33 am    Post subject: Reply with quote

What I also often do is visit a bookstore where they have a big assortment of computerbooks. Then I check if they have the books I'm looking for and see for real if they are any good to me. Also, Amazon often offers a 'peek' view into books to give you an idea what's the book like.
This might help you in deciding if the book is right for you.
Back to top
View user's profile Send private message
TheDrunkenMaster
Just Arrived
Just Arrived


Joined: 09 May 2004
Posts: 0


Offline

PostPosted: Mon May 17, 2004 3:30 pm    Post subject: Reply with quote

I truly appreciate the amount of feedback i'm getting here, but i think i may have left out some details. As far as programming languages go i know the following : HTML, Java-script, JAVA, and a little of action script. I have also spent a little of time with Perl and VB before. But, even though i have learned quite alot, none of it really gave me any basis on raw coding. My dad is a programmer, but to tell u the truth me and him don't get along very well..... Sad Anyway, he has some books that might be of interest for me. I will look into everyones ideas and opinions and i will decide how i want to go about this. After all it is my decision. Twisted Evil
Back to top
View user's profile Send private message
Invisible
Just Arrived
Just Arrived


Joined: 21 May 2004
Posts: 0


Offline

PostPosted: Fri May 21, 2004 3:31 pm    Post subject: Reply with quote

To help you decide a little better, here's my opinion (and my first post Wink).
Like the majority said, I'd go for C. C is a flexible high level language and once you understand C it will be easy to learn another language. It doesn't work in the other direction. First learning Basic and then learning C is like starting all over again.
Stay away from assembler at least untill you got enough experience with programming. Assembler makes you understand the way a computer works very well, but programming in assembler is like expressing music in mathematical formulas Wink.

Anyway, that's just my opinion.
Back to top
View user's profile Send private message
Display posts from previous:   

Post new topic   Reply to topic   Printer-friendly version    Networking/Security Forums Index -> Programming and More All times are GMT + 2 Hours
Goto page 1, 2  Next
Page 1 of 2


 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

Community Area

Log in | Register