Sign in to follow this  
Simpsons4261

What language to start with?

Recommended Posts

What do you guys think the best language to start with is if I have no previous programming experience at all? I was thinking Python, but now I'm not sure as some call that a "sloppy language". I really want to become a software engineer/programmer of either software or games. Would it be best to start in C++ which is what most of the industry uses? Or should I start out on something smaller? Help would be appreciated, and if you recommend a language, also recommend a book/web site where I can learn with no previous programming experience. Thanks!

Share this post


Link to post
Share on other sites
I would recommend Python. Even if it is "sloppy" (a point on which I disagree), it's still a good language for learning the basics, and is very fast to pick up. Then you can learn the meat of programming, basics of good design, etc. You can move on to a different language later, if you want. I personally enjoy programming Python a lot.

I learned python from the built-in help file on Windows, but if you're not on Windows, I don't know for sure if it's included. It's online anyway, I think. Theres tons of stuff and links at www.python.org

Share this post


Link to post
Share on other sites
Python is almost definitely a good idea for you right now. C++ is, true, used a lot in the industry, but it can be difficult to learn right off the bat.

I was going to say more, but my head hurts...

Share this post


Link to post
Share on other sites
It doesn't matter.

If you're going to become a software developer, you're going to learn multiple languages eventually, and the language you start with will not determine how good you become or which other languages you learn later. What is important is that, once you've picked a language, you stick with it long enough to solve problems adequately.

Python's a fine choice, though.

Share this post


Link to post
Share on other sites
C++ is a difficult language to start off with. It has everything from a chisel and a hammer to some high powered machinery and bulldozers, which can hurt you a great deal if you don't know how to use them properly.

Instead, begin with a simple language. Almost any language will do, they should all pretty much have the same basic concepts:

- condition statements, for checking when to do "stuff"
- loops, for repeating "stuff" until you tell it to stop
- some sort of data structures, for holding and manipulating all your information

Once you've got the basic concepts down, learning any new language is a MUCH easier task. There are concepts in C++ such as object-oriented programming which can be very daunting and difficult to grasp if you don't have a clear understanding of the basics first.

Personally, I learnt with QBasic (mostly because I didn't know better), and its a ridiculously simple language. Qbasic will teach you all the basics of programming very quickly, but the syntax is almost nothing like C/C++ and it will probably teach you some really nasty habits. Nevertheless, the basics are there, and it shouldnt be too hard to move to a slightly more difficult language like C (which is C++ minus all the hard stuff).

Regardless of the language you choose, once you know one of them, the rest are reasonably easy to learn. From Qbasic I went to C, then to Java, then C++ and I had a reasonably enjoyable time. As a programmer, you will probably end up learning many many many more languages, the knowledge of each will be just another tool to add to your collection.

As for books, I would go to the local library once you've chosen a language and take a look to see if theres any decent books you can learn from there. If there isn't, then an Amazon search would be the next place to go and check out all the reviews and ratings for some of the different books. Pick the best one, and supplement your learning with other online tutorials and documentation.


Share this post


Link to post
Share on other sites
I just started learning programming myself using Python because I heard it was a good language to start with from many a people. Clearly they weren't lying, because I've seen some of C++'s syntax and it can be quite nasty to a newcomers like ourselves. Let me just make a quick comparison;

#include <iostream.h>

main()
{
cout << "Hello World!";
return 0;
}

That snippet of code is how you would display the text "Hello World" in C++, and this is how it would be done in Python;

print "Hello World"

Big difference there. If you do choose Python there are plenty of good tutorials and guides to using the language. I have many bookmarked, so if you need some let me know.

I started with this one, http://en.wikibooks.org/wiki/Non-Programmer's_Tutorial_for_Python/Contents , but there are tons more.

Share this post


Link to post
Share on other sites
Quote:
Original post by Oluseyi
It doesn't matter.

If you're going to become a software developer, you're going to learn multiple languages eventually, and the language you start with will not determine how good you become or which other languages you learn later. What is important is that, once you've picked a language, you stick with it long enough to solve problems adequately.

Python's a fine choice, though.


Mostly you're right, but I think it's over-kill to say that your first language choice doesn't matter. You want to pick a language that makes it easy to "stick with it", as you said. [smile]

Share this post


Link to post
Share on other sites
Python is a perfectly capable language which is sometimes used in the industry and with which you should be able to find plenty of help and resources available.

Any language will do as long as you stick with it.

Share this post


Link to post
Share on other sites
I'm not sure where you heard of Python being "sloppy"? but I'd be wary of this source since obviously they've never used Python long enough to even type import this in Python!
"Beautiful is better than ugly.
Explicit is better than implicit.
Simple is better than complex.
Complex is better than complicated.
Flat is better than nested.
Sparse is better than dense.
Readability counts.
Special cases aren't special enough to break the rules.
Although practicality beats purity.
Errors should never pass silently.
Unless explicitly silenced.
In the face of ambiguity, refuse the temptation to guess.
There should be one-- and preferably only one --obvious way to do it.
Although that way may not be obvious at first unless you're Dutch.
Now is better than never.
Although never is often better than *right* now.
If the implementation is hard to explain, it's a bad idea.
If the implementation is easy to explain, it may be a good idea.
Namespaces are one honking great idea -- let's do more of those!

"

Anyways here's a cool free Python book I just came across that look promising:
Invent Your Own Computer Games with Python, Book 1


[Edited by - daviangel on July 7, 2008 12:24:52 AM]

Share this post


Link to post
Share on other sites
Quote:
Original post by Jonathan5
#include <iostream.h>

main()
{
cout << "Hello World!";
return 0;
}

Is that actual code from a learning resource or just your paraphrase? Because there you have one more problem with C++: a lot of learning resources are outdated and terrible. Problems:
- You should include <iostream> instead of <iostream.h>
- main() should be int main()
- cout should be std::cout
- the return 0; can be omitted

Share this post


Link to post
Share on other sites
Go with C++. It's what all the pros use. You wanna be a pro, use it.
And BTW, name some big players in the game business (id, Microsoft, Blizzard, Capcom, Epic, Monolith etc) that have EVER used Python... None whatsoever!

Yeah, it's a bit hard, and you have to watch your step like you're in a mine field, but anything is better than to spend ~2 years learning Python, hit its limits, then spend ~2 more years learning how to do it in C++.

Share this post


Link to post
Share on other sites
Quote:
Original post by asdqwe
Go with C++. It's what all the pros use. You wanna be a pro, use it.
And BTW, name some big players in the game business (id, Microsoft, Blizzard, Capcom, Epic, Monolith etc) that have EVER used Python... None whatsoever!

Yeah, it's a bit hard, and you have to watch your step like you're in a mine field, but anything is better than to spend ~2 years learning Python, hit its limits, then spend ~2 more years learning how to do it in C++.


This is terrible advice and also just plain incorrect.

If you want to learn to ride a bike do you start with the types of bikes the pros use? No, you probably start with a tricycle or at least some training wheels.

An entire "big player" game in Python probably doesn't exist but that doesn't mean it hasn't been EVER been used in them.

Share this post


Link to post
Share on other sites
Quote:

Go with C++. It's what all the pros use. You wanna be a pro, use it.
And BTW, name some big players in the game business (id, Microsoft, Blizzard, Capcom, Epic, Monolith etc) that have EVER used Python... None whatsoever!

Yeah, it's a bit hard, and you have to watch your step like you're in a mine field, but anything is better than to spend ~2 years learning Python, hit its limits, then spend ~2 more years learning how to do it in C++.


What 'big name players' use is entirely irrelevant to the topic of what a beginner should use. Your advice is horrible.

Share this post


Link to post
Share on other sites
First of all, I have myself started with C++ at a young age.
Second, the "big players" reference was meant to create some enthusiasm, something to fall back on when encountering C++'s pitfalls.
Third, if he's the "I want it now" type, he can download Gamemaker.
It may not be a regular language but it has GML (GameMaker Language)- easy and chock-full of useful mouse, keyboard, sound, even video functions, hardware-accelerated. I've tried it and it gets results done much faster than Python. It even has a level editor.

Share this post


Link to post
Share on other sites
Quote:
Original post by DevFred
Quote:
Original post by Jonathan5
#include <iostream.h>

main()
{
cout << "Hello World!";
return 0;
}

Is that actual code from a learning resource or just your paraphrase? Because there you have one more problem with C++: a lot of learning resources are outdated and terrible. Problems:
- You should include <iostream> instead of <iostream.h>
- main() should be int main()
- cout should be std::cout
- the return 0; can be omitted


That was actual code from a learning resource, and yes, I do think it is outdated. As you said, things like the return can be removed, etc. I just googled in "Hello World C++" really quick to give him an example because either way I knew it was much more complex than just simply, "print".

Share this post


Link to post
Share on other sites
MIT starts its students off with Java.
My first CS course was about Java.

Take Java.

Its syntax is a nice introduction for C++, looking similar on the surface.
No memory management needed, it is all handled for you by that Garbage collector.

Chances are, if you end up studying computer science, they are going to feed you either C first, or Java first. Both will pretty likely be waiting you down the road. It sure is not the fastest, neither is it the greatest.

But it is widely used in the non-game industries. And after so much time and studying, switching to C++ wont be as much of a chore as it were from our previous computer science opener: Pascal.


Share this post


Link to post
Share on other sites
Quote:
Original post by Stoo
Take Java.

Its syntax is a nice introduction for C++, looking similar on the surface.
No memory management needed, it is all handled for you by that Garbage collector.


I believe Java is a good language to learn about object-oriented style programming, though the way generics and some things like that have been implemented is a little bit questionable.

Though for a complete beginner, I think OOP is a little too advanced to learn straight off without some sort of formal guidance by a college/school. I remember I found it quite alien and difficult to grasp the first time I was introduced to classes and the idea of static variables, objects and dynamic binding.

I think it would be better to start off with a simple procedural language first and then move on to something a little more complicated like Java once you get the basics down. It doesn't have to be for 2 years like mentioned above, just until you are confident with the basic ideas, and then moving onto another language like C or Java would be good and much much easier. I think C would be a little bit better because while it has memory management (which is again good to know), the idea of pointers and structs is a good thing to know when thinking about objects and accessing their members. Also, C is pretty much still a procedural language so it's not a huge leap from other simpler languages.

After all, C++ supports a wide variety of programming paradigms, from monolithic spaghetti code, to procedural structured with functions, to functional, to OOP etc. I think that if you get into the habit of using OOP too early on, you will end up overusing inheritence and other powerful tools and will be tempted to overcomplicate your design. Since Java is purely OOP, it probably isn't ideal to learn straight off.

Another advantage of C, is that it basically introduces you to the syntax of alot of other similar languages including Java, perl, C++ etc. And once you know C, you can be fully appreciative of the advances in memory management and the garbage collector of other languages like Java. Not to mention that millions of lines of code have already been written in C, which means theres ALOT of tutorials and documentation out there to help you learn more.

Of course, this is all still my personal opinion. Really any language is fine to begin with, just some languages will be harder than others for a beginner. Ultimately, you will learn most of the relevant ones anyway, and once you know one, its pretty much a matter of syntax to learn all the others.

Share this post


Link to post
Share on other sites
I wouldn't start with Java just for the sake of learning OOP, If you wanted to do that just go with C++, i started with lua, a nice little scripting language, fortunatly its a fairly commonly used language in the industry (crysis and WoW to name a couple of the better known games), my first attempt at programming was Java and that failed horribly, as people have mentioned, you will have to learn several languages eventually, so starting like a small (and sloppy) language like python or lua first and then learning somthing a little more robust (i would suggest learning Java and C++) so that you can make some finer programs.

well thats my 2 cents

Share this post


Link to post
Share on other sites
If It was me, I would go with c#. Its simple enough to grasp and yet strong enough to be compared to c++. Another reason is its massive support from microsoft

Share this post


Link to post
Share on other sites
Quote:
Original post by asdqwe
BTW, name some big players in the game business (id, Microsoft, Blizzard, Capcom, Epic, Monolith etc) that have EVER used Python... None whatsoever!
Firaxis Games (Civilization IV), CCP Games (EVE Online), Disney (Toontown Online, Pirates of The Caribbean Online). Notable non-games industry users include Industrial Light and Magic and Google amongst many others -- including, to pluck an entry from your list, albeit outside of their games business, Microsoft (see here for one example).
Quote:
Second, the "big players" reference was meant to create some enthusiasm, something to fall back on when encountering C++'s pitfalls.
That may have been your intention, but it doesn't make you any less outright incorrect.

Share this post


Link to post
Share on other sites
Pick a language out of a hat. Seriously. Arguing over which language to start with is far less productive than picking the "wrong" language and at least getting started. Yeah, the language may be difficult, and you may pick up some bad habits; so what? The software developer's journey is a long one, and you'll be compelled to learn a lot of stuff (which may seem irrelevant at times).

Just start, okay? Everyone wants to tell you to do what they did, or use whichever language they like. Whatever. Just start.

Share this post


Link to post
Share on other sites
Can anyone explain to me what 'sloppy' means in regards to Python here? I literally have no idea what some guys are talking about. The only weakness is runtime performance, as far as expresiveness goes it is a language much better than C++ or Java.

Share this post


Link to post
Share on other sites
Quote:
Original post by mikeman
Can anyone explain to me what 'sloppy' means in regards to Python here? I literally have no idea what some guys are talking about. The only weakness is runtime performance, as far as expresiveness goes it is a language much better than C++ or Java.


Perhaps they are referring to significant white space? Some people feel that it's less structured. Personally, I don't like it (white space significance that is), but I've only used C-style languages, so it's a difficult change to make.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this