|
United States24513 Posts
I've talked a bit about computer programming on TL before, but honestly it was years ago and I haven't given it much thought since. Before I start, here is a brief background in my coding experience:
+ Show Spoiler +In high school I took a half year course in Visual Basic, a half year course in Java, a half year course in C++, and then I did a full year course (AP Comp Sci) in C++ (last year it was in C++ before it switched over to java). All of my C++ coding was done in the Borland C++ 5.02 IDE (I probably couldn't code in C++ without it rofl). In my spare time over the next couple of years I made some more programs in C++ as I was the most experienced in it and preferred it the most among the languages I had experience with.
I'm kind of sad that I don't do any computer programming anymore. In my spare time (when it comes up in the future at least) I should try to get back into coding. I don't need to be a professional coder, but I enjoyed computer science and liked being able to make useful programs (the idea of making games for fun or on the side is also appealing even though I realize it isn't something I could become capable of overnight). Let's say I decide I want to get back into it. The two question are:
1) What language should I focus in; how do I get started software-wise 2) What resources should I use to help me brush up and then learn new information?
I don't foresee myself taking any programming classes at a college so I'm going to have to try to do this myself. Perhaps other people have preference regarding those two questions (and other readers might benefit from reading about those preferences as well).
I just read the following which gave me some ideas, but I'm still kinda lost: http://regulargeek.com/2009/02/11/what-programming-language-should-i-learn/
What are the pros/cons of continuing with C++? If I liked C++, what is another language that I will probably also like that will be more useful? Ultimately, I know the most important question I need to answer myself before anyone can truly help me is what I plan to do with the language I choose to code in. Aside from my earlier answer of (enjoyed programming; make useful programs; possibly make games) I really don't know.
My fear is I will spend many hours learning to program in a language, and it turns out it is the worst language for doing whatever I want. Please share your thoughts!
|
Man, if you are a creative mind, pick up Java Android and become billionaire with your awesome app that took 2 days to code up! :D
Once you know OO, then learning another OO language equals learning the language syntax, so stick with whatever language you feel more confortable with. With my biased take on it, I would go with Java.
|
From my experience and from seing friends who are in the field the 2 most important programs to learn are PHP and C++.
After it really depends on what u want to create most professionnal websites are made in PHP, while alot of them can also be made in C++, PHP is considered more safe and more reliable.
Seing as u are in games u should continue with C++ and maybe add a bit of java in there just for good mesure. Ill leave the explanation of the program to someone more competant than myself.
|
On February 04 2012 06:57 fabiano wrote: Man, if you are a creative mind, pick up Java Android and become billionaire with your awesome app that took 2 days to code up! :D
Once you know OO, then learning another OO language equals learning the language syntax, so stick with whatever language you feel more confortable with. With my biased take on it, I would go with Java.
java is a really easy to learn and doesn't have complicated function like loopholes that u can do in c++ and in PHP. Going that route is the easy way but will hinder u in the long term
|
Hyrule18947 Posts
On February 04 2012 06:58 Darkren wrote: From my experience and from seing friends who are in the field the 2 most important programs to learn are PHP and C++.
After it really depends on what u want to create most professionnal websites are made in PHP, while alot of them can also be made in C++, PHP is considered more safe and more reliable.
Seing as u are in games u should continue with C++ and maybe add a bit of java in there just for good mesure. Ill leave the explanation of the program to someone more competant than myself. "wat" basically covers how I feel about everything you said here
Fuck PHP. It's too easy to learn just enough, and extremely hard to learn what you should know. Stick with C++ or go with C#.
In fact, just go with C#. As for how to actually learn how to use it, there's a few schools of thought: 1. Take a class/read a bunch of tutorials/buy some books, etc 2. Dive in
Personally, I like method 2. I learned a lot of my programming by just downloading sources of things and playing with it until I learned what everything did. This method isn't for everyone though.
|
It depends on what you want to do. If you want to code stuff for Windows, I reccomend learning C# with Visual Studio. Visual Studio is basically cheating when it comes to UI programming, it literally does everything for you.
If you want to code mobile apps, learn Java (really similar to C#) and learn Android. It's a very simple to understand framework for coding and there are Visual Studio-esque tools for it (Eclipse with Google's own addon).
|
United States24513 Posts
Thanks so far for weighing in... someone on IRC just recommended Javascript to me. When I asked what it does and doesn't allow me to do, he said everything and nothing... so a strong endorsement.
|
On February 04 2012 07:14 Sc1pio wrote: It depends on what you want to do. If you want to code stuff for Windows, I reccomend learning C# with Visual Studio. Visual Studio is basically cheating when it comes to UI programming, it literally does everything for you.
If you want to code mobile apps, learn Java (really similar to C#) and learn Android. It's a very simple to understand framework for coding and there are Visual Studio-esque tools for it (Eclipse with Google's own addon). Or go learn Objective-C and program for iOS
But you'll need a Mac OS to use Xcode to program.
|
stick to c++ at least you'll know how to manage your memory, and as the syntax of most of the programming languages is similar to C/C++ you wont have difficulties with learning new language.
But if you want to go supercasual with that try python - it has garbage collector all kinds of magic programming stuff and syntax which forces readable code.
And as for learning i'd recommend you to create your own game. It doesnt need to have awesome graphics - you can make just text-based one( you dont need to know much to do it, just how to handle strings and some loops/conditional instructions if you want to make it really simple later on you can add dialog lists quests and stuff) , but during that you will learn how to manage your code and all needed language constructs. After that hit a 2d game and later on maybe 3d?
|
United States24513 Posts
I haven't made a decision yet but I think it's clear that C++, given my experience and its usefulness is a good candidate for the language I should choose to work with more. If so, what is the best way to me to get started? I will need:
1) The software to compile/run the code (I liked coding in Borland so maybe I should use an IDE?) 2) An informational resource (or multiple) that I can use to look things up, and maybe to teach myself coding (in addition to learning by experience)
|
Since you don't clearly know what kind of things and on which platform your going to do, I would suggest you to go with C# :
- easier than C++, and good follow up since it's your base
- object oriented language, which means that at the end of the day if you want to change and learn another language (java, python,php) you will already know the concept of most of the other languages thus you will be able to transition without too much problem.
- The diversity of environment you can work on :
--Web (Asp.net,Silverlight)
--Desktop (WPF,Windows Form,Window 8 apps)
--Phone : --- Applications with silverlight --- XNA games
|
On February 04 2012 07:06 tofucake wrote:Show nested quote +On February 04 2012 06:58 Darkren wrote: From my experience and from seing friends who are in the field the 2 most important programs to learn are PHP and C++.
After it really depends on what u want to create most professionnal websites are made in PHP, while alot of them can also be made in C++, PHP is considered more safe and more reliable.
Seing as u are in games u should continue with C++ and maybe add a bit of java in there just for good mesure. Ill leave the explanation of the program to someone more competant than myself. "wat" basically covers how I feel about everything you said here Fuck PHP. It's too easy to learn just enough, and extremely hard to learn what you should know. Stick with C++ or go with C#. In fact, just go with C#. As for how to actually learn how to use it, there's a few schools of thought: 1. Take a class/read a bunch of tutorials/buy some books, etc 2. Dive in Personally, I like method 2. I learned a lot of my programming by just downloading sources of things and playing with it until I learned what everything did. This method isn't for everyone though. I agree with the method 2 thing! You can always get books/check online/ask online if you get stuck, and as people say you learn by doing!
Also language wise, if you feel comfortable, you may aswell stick to it. If you feel like trying out another language for experience i would try Csharp. For an idea, there are visual studio "express" editions that you can use for free! Lots of love -Shanks
|
learning a language is easy dude, anyone can learn a new programming language in a few hours the hard part is learning concepts, like efficient algorithms/data structures and knowing how to program object-oriented vs functional You always try to make ur code as simple and readable as possible
anyway, CS is probably the easiest field to find a (good) job in
|
The secret about programming languages is that you can program anything with any language, if you know what you are doing. If you want to continue with C++, GNU provides a free C/C++ compiler. There is no IDE, so you have to get used to editing the text files yourself. But arguably, this is more enjoyable for recreational programming anyway. The jumpstart that an IDE gives you is useful if either (a) you are on a deadline, and don't have time to learn how the language / libraries work, or (b) you spend so much time programming that you can learn exactly how all the IDE's features work. When you are programming for fun, the IDE really gets in the way(*).
You should consider learning another language. C++ is probably one of the most complicated languages out there (especially in terms of syntax), and is fairly low-level. A high-level language with a garbage collector makes your life a lot easier. My personal favourite is scheme, a very simple language with a number of implementations. Java and C# are both very good object-oriented languages. Python is probably the most popular recreational programming language right now. I personally love Javascript, but I don't think it is very good for a beginner, because it is very free-wheeling, and consequently makes it very easy to write buggy code.
(*) The exception is GUI programming, which can be a real pain to do with an IDE. However, some of the Java GUI libraries are pretty easy to use without an IDE.
|
Yo, micro. PM me what it is you want to do and I'll talk you through some of the best choices for you to start from and hook you up with the relevant tutorials and resources. Specific problems are typically more efficiently attacked with specific solutions. Even simple projects are often worth investing an hour or two learning a new language for simply to leverage features that might save countless hours in the future. Don't have time to drop a comprehensive knowledge bomb here, but in response to
What are the pros/cons of continuing with C++? If I liked C++, what is another language that I will probably also like that will be more useful? Ultimately, I know the most important question I need to answer myself before anyone can truly help me is what I plan to do with the language I choose to code in. Aside from my earlier answer of (enjoyed programming; make useful programs; possibly make games) I really don't know.
C++ is a compiled object-oriented language. If you care about performance and don't want to code in assembly or vanilla C, C++ is the go-to solution. If you don't care about performance, i.e. you're okay with a constant-bounded additional use of memory or CPU, then other solutions are easier and more effective. Java, for example, is the language of choice for many large software companies, since there are many reliable open source tools for developing and testing for Java. Also, documentation in Java via Javadocs is uberstandard, whereas documenting C++ is a bit more of a hassle since different projects use different systems, many of which are not automatic and thus might fall out of sync with the latest version of code.
From your perspective, none of this really matters. Learning C++ or learning Java first is pretty much irrelevant since they are very similar in terms of both their core features and their syntax. I've ported entire packages from one language to the other in a matter of minutes, with almost all of it being verbatim copypasta. (There are silly little things, like class declaration semicolons in C/C++ and Java requiring braces even for one-line commands, while C/C++ let you implicitly leave out these braces). You have to do a bit more work in C++ (writing your own Make files or configuring Automake, deciding whether functions are inline or not, having to deal at least a little bit with memory allocation/deallocation), and there are still some silly issues based on how C++ was built that make certain seemingly obvious tasks like circular dependencies require some simple but nonobvious hacks. On the other hand, Java tends to have more conventions in place and restricts your freedom a little bit more to force you to express yourself in pre-set, but universally understood, ways. This might also be good for you as a beginner since style and structure are the key things that make for a good program. (In C/C++ you might be tempted to use a shitload of macro preprocessor commands simply because you can and you will regret it later). Language and syntax is just an afterthought. In the end of the day, you should probably learn both languages, but the real question is whether you are willing to invest the time into understanding how computers work. If you care to learn about memory management, build dependencies, object (data and method) representation, then learn C++ first. If that stuff sounds boring and meaningless to you (which it is in all but the most CPU/Memory bottlenecked applications; the software used and developed in much of the IT industry is disk or network bottlenecked so this shit doesn't matter) then start with Java.
|
On February 04 2012 07:19 micronesia wrote: Thanks so far for weighing in... someone on IRC just recommended Javascript to me. When I asked what it does and doesn't allow me to do, he said everything and nothing... so a strong endorsement.
What he said is basically true I have learned to really appreciate the power of Javascript. However I wouldn't recommend learning programming from Javascript it is way to hard to learn correctly (since it is conceptually very different) and easily abused. Also a lot of the Javascript tutorial content online is of very dubious quality. In many ways it is the opposite of what you should learn as your first language.
Something like C# or Java would be a better choice. C# is great because a lot of the learning resources are good and you can get applications up and running quickly.
|
On February 04 2012 08:55 nekoconeco wrote:Show nested quote +On February 04 2012 07:19 micronesia wrote: Thanks so far for weighing in... someone on IRC just recommended Javascript to me. When I asked what it does and doesn't allow me to do, he said everything and nothing... so a strong endorsement. What he said is basically true I have learned to really appreciate the power of Javascript. However I wouldn't recommend learning programming from Javascript it is way to hard to learn correctly (since it is conceptually very different) and easily abused. Also a lot of the Javascript tutorial content online is of very dubious quality. In many ways it is the opposite of what you should learn as your first language. Something like C# or Java would be a better choice. C# is great because a lot of the learning resources are good and you can get applications up and running quickly. Agreed. Javascript is like the hybridest of hybrid languages. It is extremely multiparadigm and there are so many different frameworks that have been built on top of it. Problem is.... nobody really uses vanilla JS anymore. People use JQuery or MooTools or Prototype. (The last of which supports some emulated classical inheritance which is super nice) While JS is turing complete in terms of its expressiveness, the libraries available to it are limited because it exists in a web browser (Though certain server-sided technologies use Javascript interpreters as well, though I'm not sure why, since it's syntactically almost identical to Java except for typing...)
|
I am not a programmer by trade, but I programmed a large (~15k lines of code) mathematical model for my (Maths) thesis in C++. This comes off an undergraduate CS degree.
So let me be a little controversial and recommend that you not start with a compiled language, especially C++. Compiled languages (take your pick!) are awesome things, but they're like the power tools of the programming world -- big, fast, and dangerous. Doing something right in a compiled language usually means having a big project, and that means doing design in advance and knowing what will work ahead of time.
As a novice, what you're missing is the "language" of programming -- what algorithms are common, what they do, what problems are easy to solve, and what problems are hard. All of that is computer science education, and none of that is programming.
Instead, I'd recommend you pick a simple, interpreted language (I'm partial to python, myself) and go through some introductory CS material. Pick some lightweight projects you want to do, then see if the language you're using will make those things easier.
(Inside baseball: one of the reasons I really don't recommend C++ as a starter language is because of its lack of data structures built-in. You have to use the STL or Boost libraries, which are an extra layer of complexity. Since some really common projects boil down to "read in some text, parse it, do something with it, and write out the result", not having strings or hash tables/associative arrays as a built-in data structure just makes life difficult.)
Oh, one addendum: if you're okay with it, I highly recommend a Linux-type environment for programming. The entire Unix-style toolchain is pretty much built to make programming easier, whereas Wndows-based programming tends to have a "walled garden" around an IDE (integrated development environment) program. Cygwin will install an entire unix-type toolchain on a windows system. But to really get the most use out of it, you have to already be comfortable with a command line.
|
I agree with people who say c#. It is a very easy language to pickup, and it's also a "serious language", with which you can see results fast.
Why c#(or java for that matter..) over c++ (for a beginner)The curve is a LOT easier, no garbage collection to worry about,dangling pointers, etc. It holds your hand a bit, and prevents you from falling down, so you can get the basics done a lot easier. If you want to program games, you can do that with xna and c#, it is actually very easy to get started on wp7 programming with c#, c# also serves as the backed end for aspx pages and silverlight. c# also enforces oops styles on to you, whereas c++ it's possible to write c-style code which might lead to some confusion. Once you learn c#, c++ is going to be a little bit easier, cause you know how to program in general, you could learn the advanced concepts in c++ a little quicker, and maybe it wont be as frustrating(it's very easy to shoot yourself in the foot with c++).
Think of c# as sc2, and c++ as brood war :p
Javascript isnt really a language, it's a script..so I think your better off learning a language instead of a script, they could get you into some bad habits/sloppy code etc. It's much better if you learn a proper language and then use scripts on top of it to make your life easy.
Edit: one more thing is, if your on windows,use visual studio for an ide,....as a beginner, it was a so easy to use vs and not worry about random things not working, all you had to do was type your program and press F5. Later while setting up my dev environment for android..I realized how easy vs had made things for me. I think it's better to have less things to worry about while learning something and then expanding on it.
|
On February 04 2012 09:01 Gummy wrote:Show nested quote +On February 04 2012 08:55 nekoconeco wrote:On February 04 2012 07:19 micronesia wrote: Thanks so far for weighing in... someone on IRC just recommended Javascript to me. When I asked what it does and doesn't allow me to do, he said everything and nothing... so a strong endorsement. What he said is basically true I have learned to really appreciate the power of Javascript. However I wouldn't recommend learning programming from Javascript it is way to hard to learn correctly (since it is conceptually very different) and easily abused. Also a lot of the Javascript tutorial content online is of very dubious quality. In many ways it is the opposite of what you should learn as your first language. Something like C# or Java would be a better choice. C# is great because a lot of the learning resources are good and you can get applications up and running quickly. Agreed. Javascript is like the hybridest of hybrid languages. It is extremely multiparadigm and there are so many different frameworks that have been built on top of it. Problem is.... nobody really uses vanilla JS anymore. People use JQuery or MooTools or Prototype. (The last of which supports some emulated classical inheritance which is super nice) While JS is turing complete in terms of its expressiveness, the libraries available to it are limited because it exists in a web browser (Though certain server-sided technologies use Javascript interpreters as well, though I'm not sure why, since it's syntactically almost identical to Java except for typing...) You don't understand JS
I still highly recommend JavaScript, micronesia. While some of the things people have said are true (you can definitely shoot yourself in the foot if you start to abuse the languages features and use things in the wrong way), the flexibility that JS gives you makes it extremely powerful. If it was your first language ever, I don't think it'd be a good fit, but you clearly have some background in programming that I think is enough. On top of that, JS gives you some amazing capabilities. In a web browser, you can make amazing interfaces and GUI applications with it. On a server, you can do all kinds of cool responsive networking and interactive applications.
On top of all of that, the Node.JS community (which is what you'd use to run JS outside of a web browser) is really awesome, and there are modules for all kinds of things (AND they're really easy to install!). I've used a ton of different languages over the years and I've never been so happy with one as I am with JavaScript.
Some links: - Douglas Crockford is an excellent resource on JS things (although he can be a bit of an ass): http://javascript.crockford.com/ - Node.JS is the best: http://nodejs.org/ - The NPM repository lets you search for packages easily: http://search.npmjs.org/ - JSHint is super useful for checking the quality of your code: http://www.jshint.com/
|
|
|
|