Page 1 of 2
Learning to program....
Posted: Fri Nov 02, 2007 9:26 pm
by joegiampaoli
I would really like to learn how to program.
I hear python is a damn good language, especially since it's a system wide like java. I am sort of interested in learning python, so I can write my own blender plugins and such, also I would like to try making a game, in 3D, and other type of 3D appz, does anyone know of good resources? Even a book I could get a hand on?
Is python worth it? For a beginner like me?
Please don't tell me to start off with some "kindergarten" language, I want to avoid loosing time and start programming during my learning curve.
What other strong language do you recommend? Especially since I am on Linux?
Thx
Joe
Posted: Fri Nov 02, 2007 9:40 pm
by psor
Hey Joe!
Well, ... I'm not a coder even if I had my hands on PHP for a while, it's to
long ago. AFAIK python is worth it to learn, yes for a beginner too. But man
I would say it's NOT good for any *serious* 3D stuff! So yes give python a
try, should be pretty straight forward to learn, ... but then get your hands on
C/C++ and OpenGL if you really want to do 3D coding. there are a lot of
sites, especially from the "demo scene" that are just there to help ya out.
Don't have the time right now to get you the right links, but I guess you've
got a bit time and are not in a hurry ... hehe. ;o)
... I'll tune in later. *G*
take care
Oleg aka psor
Posted: Fri Nov 02, 2007 9:43 pm
by joegiampaoli
KK, Thx psor

, I'll check on C/C++ with OpenGL, I'm just getting on a stag of life where I feel a little bored and want to do some new stuff.

Posted: Fri Nov 02, 2007 9:44 pm
by psor
Hmm, ... somehow I feel ya, hehe!
take care
psor
Posted: Fri Nov 02, 2007 10:45 pm
by Stur
C# is more friendly to my opinion, and (according to Microsoft), as fast as C++.
Just a matter of taste, both are good.
Posted: Fri Nov 02, 2007 11:05 pm
by WytRaven
Nothing running under a virtual machine can ever be as fast as native code. simple.
That said it doesn't mean that C# is slow, just not as fast as C or C++ can be.
Posted: Sat Nov 03, 2007 12:51 am
by Nortmobile
Well I would say start with C++. If you're looking to do gaming then C++ and focus on OpenGL or DirectX. But remember OpenGL is for graphics only so to make a whole game you will need to use other APIs. DirectX does have some advantages of doing other thing besides graphics, like it has handlers for some networking, sound, and controls(mouse, keyboard, joystick). DirectX is a Microsoft entity so it will be hard (or impossible) to program in Linux although I think there are some DirectX "clones" that you could check out. C++ is a very powerful language and should allow you to do basically anything you want to do. There is a much bigger learning curve but because it's been out so long, there are a ton of tutorials and book that you should be able to get.
So C++(or C#) is the way to go unless you find yourself a coding savant then go with with ASM.
Posted: Sat Nov 03, 2007 2:19 am
by Kram1032
wouldn't ogre3D be such an Open Sourced DX?

Posted: Sat Nov 03, 2007 2:43 am
by WytRaven
i wouldn't recommend ASM as a first language simply because it is bizarre to ssay the least and it's very easy to write bad ASM code. I would suggest learning C followed by stepping into C++ and then taking a look at ASM to get an indepth idea of how things really go on. learning C and C++ will pretty much give you a head start on any other language as many many languages out there are based on one of these two.
Posted: Sat Nov 03, 2007 3:42 am
by IanT
Nothing running under a virtual machine can ever be as fast as native code. simple.
That's a
slightly sweeping statement

The difference is usually negligible for most applications, especially if the language in question has a JIT compiler.
Java or C# would probably be fine for 99% of anything you'd ever need to do. C++ (and I've done plenty of it over the years) would be horrendous as a "my first programming language".
Python is great (but slow). Java is also great and significantly faster than Python. Both run happily on any platform.
Ian.
Posted: Sat Nov 03, 2007 4:37 am
by WytRaven
C++ (and I've done plenty of it over the years) would be horrendous as a "my first programming language".
I didn't suggest C++ as a "My First Programming Language" I suggested C, a procedural language with no clunky object crap to get in the road of learning the basics of programming. It will also not hide anything from you so you can break stuff if you want to in the name of learning.
That's a slightly sweeping statement

The difference is usually negligible for most applications, especially if the language in question has a JIT compiler.
...countering one sweeping statement with another...interesting
Java is also great
Learning to code using a system that completely hides the machine from you is not my idea of a good plan. Garbage collection etc just encourages bad programming habits from the get go. This also applies to C#. If you can't be trusted to manage memory yourself then you have no bloody business writing code in the first place.
If you are going to learn to code, learn to code well.
Posted: Sat Nov 03, 2007 4:43 am
by IanT
...countering one sweeping statement with another...interesting
Haha, touche

I should have prefaced that with "in my experience".
There's a trade-off between doing one's own garbage collection (and the many hours of debugging and hair-pulling that comes with it) and having something else do it for you. There are several other benefits too (some even to do with performance) so it's not all bad.
If "something else clearing up the rubbish" is your only objection to a VM-based language then I'd say it's not the right objection that should put off a new programmer from learning that language.
Sorry to have misquoted you on the C/C++ thing ... I cut my teeth on C many many years ago and have extremely fond memories of it. I still wouldn't recommend it to a new programmer though but it's just personal opinion backed up by experience (which I'm not suggested you lack either, clearly you don't)
Ian.
Posted: Sat Nov 03, 2007 5:10 am
by WytRaven
For some reason a lot of my close friends seem to think I'm masochistic
...I tell them I just believe in learning from the bottom up not from the top down.

Posted: Sat Nov 03, 2007 5:21 am
by Nortmobile
IanT wrote:
Java or C# would probably be fine for 99% of anything you'd ever need to do. C++ (and I've done plenty of it over the years) would be horrendous as a "my first programming language".
That may be true but C(++) has been the "my first programming language" for many, many programmers, so it can be done. The programming languages that came before C, for the most part, "suck balls" or were too specialized for most people to use so people started with C.
I guess it matters on what your goal is. If you look at commercial games, most are created with C++ so if your goal is to eventually get a job coding games then learn C++. If your goal is to create a game to show your friends, make it in C#, java, or even VB(.net) or another Object-oriented programming language. If you learn C++ first, learning C# or Java afterwards should be relatively easy. Here's a good site to start with for OpenGL developement.
nehe.gavedev.net
Posted: Sat Nov 03, 2007 5:45 am
by IanT
WytRaven wrote:For some reason a lot of my close friends seem to think I'm masochistic
...I tell them I just believe in learning from the bottom up not from the top down.

Everyone to their own ... just don't leave the clamps on too long
Ian.