Hard Light Productions Forums

Off-Topic Discussion => Programming => Topic started by: jr2 on March 21, 2012, 07:38:47 pm

Title: Learning programming the hard way
Post by: jr2 on March 21, 2012, 07:38:47 pm
here (http://bit.ly/vxTeTO)  (or here (http://progmofo.com) if you're at work)

I think I'm gonna see if I can learn C (there are like a million free books on languages on that site, including graphics programming) ... IDK if it'll do any good, but,
Quote
If you don't know how to code, then you can learn even if you think you can't. Thousands of people have learned programming from these fine books:

Hmm.  Well, I once did attempt to teach myself C++ (Borland Turbo C++ or somesuch)

It was a miserable failure, because, at the time, something was wrong with my compiler (I guess)... they instructed me to create a simple program, which I did.  It would not compile.  I tried making several alterations.  No dice. 

I then proceeded to open up the answer key and I copied the correct program verbatim.  Still couldn't compile. At which point I gave up.  Not sure what the problem was, but I haven't attempted anything since.

They also have a manifesto that I copied here:

Quote
Programming, Mother****er
Do you speak it?
We are a community of mother****ing programmers who have been humiliated by software development methodologies for years.

We are tired of XP, Scrum, Kanban, Waterfall, Software Craftsmanship (aka XP-Lite) and anything else getting in the way of...Programming, Mother****er.

We are tired of being told we're autistic idiots who need to be manipulated to work in a Forced Pair Programming chain gang without any time to be creative because none of the 10 managers on the project can do... Programming, Mother****er.

We must destroy these methodologies that get in the way of...Programming, Mother****er.

* * * *
Our Values

They Claim To ValueThey Really ValueWe ****ing Do
Individuals and interactionsTons of billable hoursProgramming, Mother****er
Working softwareTons of pointless testsProgramming, Mother****er
Customer CollaborationBleeding clients dryProgramming, Mother****er
Responding to changeInstability and plausible deniabilityProgramming, Mother****er

We think the **** on the left, is really just the con in the middle, and that we really need to just do the thing on the right...Programming, Mother****er.

Signed,

Zed A. Shaw
And The Programming Mother****ers

Can anyone look at this site briefly and tell me if it's a pretty good place to learn?  Or are there other better sites?  Keep in mind that I'm not going to have time to sit down and learn this; I'm going to have to pick up bits and pieces here and there and try to keep myself interested as well.
Title: Re: Learning programming the hard way
Post by: z64555 on March 21, 2012, 09:38:36 pm
lmao... language filter fail.

what link is actually linked to:
http://www.programming-mother****er.com/become.html

EDIT: After getting past some of the hard feelings, it looks like it's got links to some interesting reads. Of course, you probably still do need a compiler that actually works. :p
Title: Re: Learning programming the hard way
Post by: Nuke on March 21, 2012, 10:24:22 pm
:lol:
Title: Re: Learning programming the hard way
Post by: Aardwolf on March 21, 2012, 10:38:00 pm
jr2, C++ can be incredibly frustrating due to the amount of "meta" stuff ... directory setup, debug vs. release, linker settings, ... such that there may be nothing wrong with your programming, but it won't work.

You can probably find instructions for how to set up your dev environment somewhere on the Internet.
Title: Re: Learning programming the hard way
Post by: jr2 on March 22, 2012, 12:07:19 am
Thanks.  And, I used bit.ly to fix the language filter bug.  EDIT: At work, you can always go to progmofo.com (http://progmofo.com).  Apparently, he recommends learning a scripting language first.  I chose Python (instead of Ruby), and I'm all set up now (finished exercise 0, setting up).

Obviously (if you read it), a lot of this stuff is familiar to me (using command line to list and create directories, and change working directories, etc), so that helps.  Hopefully I'll get something out of this in the end.  Wish me luck!  :D
Title: Re: Learning programming the hard way
Post by: BloodEagle on March 22, 2012, 02:00:38 am
Don't learn a scripting language first.

C is actually a really good place to start.
Title: Re: Learning programming the hard way
Post by: Nuke on March 22, 2012, 02:55:13 am
i definately support starting with c. high level languages are really good at hiding what goes on beneath the surface. oop is all fine and dandy when you need to organize a massive code base, but i find when youre learning the basics, like data types, control structures, pointers, functions, structs, etc, dealing with high level stuff like objects just really gets in the way. once your proficient in the basics then move on to oop. learning from the top down seems like it would be confusing. like teaching calculus to someone who doesn't know algebra. of course i dont advocate learing asm first either. the advent of the programming language is actually important because it makes programming much more accessible to everyone. asm is hard to read, hard to write, you have to memories hundreds of opcodes and know a considerable amount of information about the cpu, where programming languages proper just lets you tell the computer what you want to do and have the compiler decide which instructions best represent your code. you can completely avoid asm so long as youre not writing really tight code (and if you are the cpu is fast enough where you might not care or notice whether something took 10 nanoseconds or 10 microseconds).
Title: Re: Learning programming the hard way
Post by: Polpolion on March 22, 2012, 03:01:42 am
I suggest starting with C as well. It's pretty, simple, relatively small, and introduces you to ideas that would lead to huge frustrations if you start with a scripting language and went down in abstraction instead.
Title: Re: Learning programming the hard way
Post by: Nuke on March 22, 2012, 03:29:56 am
the cool thing about c is that once you learn it its fully featured enough to keep using it, or you can move into c++ or some other c derivative, without needing to learn a whole other language.
Title: Re: Learning programming the hard way
Post by: Spicious on March 22, 2012, 04:19:15 am
The bad thing about sliding from C to C++ is you'll most likely start off writing terrible C++.
Title: Re: Learning programming the hard way
Post by: pecenipicek on March 22, 2012, 05:20:10 am
i'm probably gonna get a lot of flak for this, but i find vb.net quite glorious. especially if you work in VS2010.
Title: Re: Learning programming the hard way
Post by: Ghostavo on March 22, 2012, 05:47:40 am
Your first imperative language is not really that important, as long you learn how some basic data structures/algorithms/control flows work.

Hell, you could always do it the hardcore way and go for full blown pseudo-code.

Title: Re: Learning programming the hard way
Post by: headdie on March 22, 2012, 07:12:11 am
Your first imperative language is not really that important, as long you learn how some basic data structures/algorithms/control flows work.

Hell, you could always do it the hardcore way and go for full blown pseudo-code.



My old programming tutor loved pseudo-code, with it helping you to translate the student scribbled "what i want to do" into usable code.  So did the ppl on the course for the other modules because they could still get marks without even if they hated programming.

Oh and this thread has encouraged me to actually find a tutorial and start relearning C for the first time in 10 years :D
Title: Re: Learning programming the hard way
Post by: Qent on March 22, 2012, 07:24:02 am
I'd say start with Scheme and work your way down to C, but that's just because that's how they taught it in school when they had some years available to teach it. :o
Title: Re: Learning programming the hard way
Post by: LHN91 on March 22, 2012, 07:44:28 am
I.... hate scheme with a passion. I agree with those that say start with C - you'll find that plenty of languages look an awful lot like C, and C is still a perfectly viable language to program in. As for compiler environment, I personally think you should set up Linux of some sort (Personal preference is something Debian based, at least in a VM) and compile with gcc; but that's likely because I've not touched Visual Studio.
Title: Re: Learning programming the hard way
Post by: Polpolion on March 22, 2012, 09:02:25 am
If Scheme is your first programming language I swear I will worship you forever.
Title: Re: Learning programming the hard way
Post by: Sushi on March 22, 2012, 09:12:46 am
Don't learn a scripting language first.

C is actually a really good place to start.

I'm gonna say the opposite. Python is a fantastic place to start and learn all the basics about programming. It's a great language. I came to this thread planning to urge you to do something other than C as a first language anyway. There's a reason why the vast majority of introductory programming courses start with Java or Ruby or Python and NOT C/C++. Those last two have a lot of extra complexity that frankly just gets in the way of learning the basics.

I really don't buy the argument that it's bad to start at a higher level of abstraction. Abstraction, after all, is what programming is all about. :)

Pick up C as a second language, and use it to write a webserver or something (although there's nothing stopping you from doing that in Python too). :)
Title: Re: Learning programming the hard way
Post by: LHN91 on March 22, 2012, 09:30:13 am
Whereas our entire University's Computing program is built around the idea that straight procedural ANSI C comes first, and then they add in C99, Java, Python, etc. later on; and IMHO, I think it's made me a better programmer. That's not to say I dislike Python, in fact I really like working with it, and if that's what you start with you could do far worse. Java is also a fairly good one to start with.

Personally, I feel though that C is actually a pretty good level of abstraction to start with. It's not assembly, but it's also not going to hold your hand and allow you develop sloppy coding practices either. A good middle-ground, if you will.
Title: Re: Learning programming the hard way
Post by: Qent on March 22, 2012, 09:54:33 am
If Scheme is your first programming language I swear I will worship you forever.
I played with Java and QBasic first, then took C++ and HTML/CSS/Javascript/Perl in highschool, then the first programming course in college used Scheme. So unfortunately I will have to turn down the nomination for godhood. :(
Title: Re: Learning programming the hard way
Post by: Nuke on March 22, 2012, 10:33:26 am
I.... hate scheme with a passion. I agree with those that say start with C - you'll find that plenty of languages look an awful lot like C, and C is still a perfectly viable language to program in. As for compiler environment, I personally think you should set up Linux of some sort (Personal preference is something Debian based, at least in a VM) and compile with gcc; but that's likely because I've not touched Visual Studio.

this is about the only thing i like about linux. gcc is ****ing awesome, it takes all the bull**** out of programming. no ides to configure, libraries are easy to get, etc. just a simple makefile is all you need. visual studio on the other hand can be such a *****.
Title: Re: Learning programming the hard way
Post by: z64555 on March 22, 2012, 12:44:22 pm
Whereas our entire University's Computing program is built around the idea that straight procedural ANSI C comes first, and then they add in C99, Java, Python, etc. later on; and IMHO, I think it's made me a better programmer. That's not to say I dislike Python, in fact I really like working with it, and if that's what you start with you could do far worse. Java is also a fairly good one to start with.

Personally, I feel though that C is actually a pretty good level of abstraction to start with. It's not assembly, but it's also not going to hold your hand and allow you develop sloppy coding practices either. A good middle-ground, if you will.

 :yes: That, and knowing several languages (even just a little bit) helps you understand their capabilities more and allows you to pick and choose the right language for the job.
Title: Re: Learning programming the hard way
Post by: Aardwolf on March 22, 2012, 01:36:21 pm
I.... hate scheme with a passion. I agree with those that say start with C - you'll find that plenty of languages look an awful lot like C, and C is still a perfectly viable language to program in. As for compiler environment, I personally think you should set up Linux of some sort (Personal preference is something Debian based, at least in a VM) and compile with gcc; but that's likely because I've not touched Visual Studio.

this is about the only thing i like about linux. gcc is ****ing awesome, it takes all the bull**** out of programming. no ides to configure, libraries are easy to get, etc. just a simple makefile is all you need. visual studio on the other hand can be such a *****.

Ha, I use gcc/g++ on my win7 (gnuwin32 ftw!)

Not for serious stuff, but sometimes if I want to write a little dinky program to test an idea and I don't want to configure solutions and projects and stuff like that.
Title: Re: Learning programming the hard way
Post by: Tomo on March 22, 2012, 01:49:12 pm
I use Qt Creator 2.4 as my primary IDE.

- It's happy with both mingw32 (gcc) and VC2010 compilers, the only difference I notice between these compilers is that gcc gives much nicer error messages and the debugger was easier to set up.

I tried Visual Studio 2010 Express but it's really painful to set up compared to Qt Creator.
(Plus jom means that Qt Creator compiles using VC2010 faster than Visual Studio does... Yes, this is madness but hey!)
Title: Re: Learning programming the hard way
Post by: BloodEagle on March 22, 2012, 03:36:43 pm
Don't learn a scripting language first.

C is actually a really good place to start.

I'm gonna say the opposite. Python is a fantastic place to start and learn all the basics about programming. It's a great language. I came to this thread planning to urge you to do something other than C as a first language anyway. There's a reason why the vast majority of introductory programming courses start with Java or Ruby or Python and NOT C/C++. Those last two have a lot of extra complexity that frankly just gets in the way of learning the basics.

I really don't buy the argument that it's bad to start at a higher level of abstraction. Abstraction, after all, is what programming is all about. :)

Pick up C as a second language, and use it to write a webserver or something (although there's nothing stopping you from doing that in Python too). :)

I haven't really had cause to check out Python, yet.  I was mainly referring to languages along the lines of JavaScript (stay the **** away from this for as long as you're able to).

I've always found error checking in compiled languages to be far easier with than in scripted ones.

---

Aside:

When / if you move on to learning OOP, you should look into Processing.  It's like Java without the overhead (though it lacks a great many features).
Title: Re: Learning programming the hard way
Post by: Mongoose on March 22, 2012, 06:41:22 pm
My programming classes in college started with C and then introduced C++, and we did all our work on a Unix shell.  I still don't know how the hell an IDE works, much less how to properly configure one...it was all gcc/g++ and Makefile for us. :p

I.... hate scheme with a passion.
I strongly agree.  I forget which course it was that was based around Scheme, but I loathed it.  The whole language is so minimalistic and ass-backwards that it requires some sort of zany sideways thinking to do even something simple.  Give me operations and loops that actually make sense in plain English any day of the week.