• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

I want to learn to program

plastick

Golden Member
Hey I'm thinking about learning how to program. I dont know what I shold learn though. What language is good for creating virtually any kind of program?
 
Originally posted by: Feldenak
I would start with C and get the basic principles down.
There are also dozens of good C and C++ books out there, and thousands of web pages.

If you are a college student may be able to get Microsoft Visual C++ (or Visual Studio) cheap. The big advantage of using VC++ is the excellent "debugger" that lets you watch a program run, one line at a time, and see how things change after each line. This will help you understand what is happening vs. what you thought would happen.
 
C++ is a good place to start. Java and Visual Basic are nice higher level languages that require less work, but you may not understand as much what is going on in the background. But those three are basically what is "in demand" from what I understand.
 
What kind of things do you want to do?

Web based? HTML, javascript, CGI (Perl, PHP, etc.), DHTML, etc.
Otherwise I'd reccomend Java it will teach you very well how to structure your programs and its the newest of all the major languages and is gaining lots of importance. Not that other languages are bad, but its the current language to learn.
 
Also, pick up some books on algorithms. Might seem boring as heck, but it will teach fundamental principles of programming and logic. You have to think in terms of logic which can be hard to grasp for some people. Reading and learning how different sorts work, for example, will show you the thinking that is behind programs.

I'd start with C or C++. C# is geared towards beginners and it similar to C. Basically, you need to learn concepts now more than a specific language. Example, a IF-THEN loop compared to a WHILE loop and when to use which.
 
Originally posted by: wyvrn
C++ is a good place to start. Java and Visual Basic are nice higher level languages that require less work, but you may not understand as much what is going on in the background. But those three are basically what is "in demand" from what I understand.

Honestly, I think C++ is a lousy place to start. Someone who's learning to program should start with basic concepts like variables, typing, and control flow, and all of the OO baggage that goes along with C++ just confuses the issue.

I know everyone here wants to be l33t and frowns on things like VB and Java, but they're far better for learning basic principles than immediately diving into the crucible of something like C or C++. You'll certainly understand more going from C++ to VB than vice-versa, but be prepared for a lot more frustration before comprehension dawns.
 
I know everyone here wants to be l33t and frowns on things like VB and Java, but they're far better for learning basic principles than immediately diving into the crucible of something like C or C++.

A good C or C++ book will start with console-style programming and will introduce the language one tiny piece at a time.

For the initial concepts there really isn't much difference between C/C++, java, VB except that with VB they have to deal with distractions like learning to draw forms and attach code to buttons, and in VB6 the type system is missing so new students will learn bad habits like adding numbers and strings together.

VB6 is a great tool, but not a great teaching tool.

 
Originally posted by: FeathersMcGraw
Originally posted by: wyvrn
C++ is a good place to start. Java and Visual Basic are nice higher level languages that require less work, but you may not understand as much what is going on in the background. But those three are basically what is "in demand" from what I understand.

Honestly, I think C++ is a lousy place to start. Someone who's learning to program should start with basic concepts like variables, typing, and control flow, and all of the OO baggage that goes along with C++ just confuses the issue.

I know everyone here wants to be l33t and frowns on things like VB and Java, but they're far better for learning basic principles than immediately diving into the crucible of something like C or C++. You'll certainly understand more going from C++ to VB than vice-versa, but be prepared for a lot more frustration before comprehension dawns.

C++ can be as OO as you make it, you can write very functional code in it if you want.
 
Originally posted by: FeathersMcGraw
Originally posted by: wyvrn
C++ is a good place to start. Java and Visual Basic are nice higher level languages that require less work, but you may not understand as much what is going on in the background. But those three are basically what is "in demand" from what I understand.

Honestly, I think C++ is a lousy place to start. Someone who's learning to program should start with basic concepts like variables, typing, and control flow, and all of the OO baggage that goes along with C++ just confuses the issue.

I know everyone here wants to be l33t and frowns on things like VB and Java, but they're far better for learning basic principles than immediately diving into the crucible of something like C or C++. You'll certainly understand more going from C++ to VB than vice-versa, but be prepared for a lot more frustration before comprehension dawns.

my first language was C, the last class before they switched to Java here... personally i feel i learned more than students do now about programming.
 
Originally posted by: royaldank
Also, pick up some books on algorithms. Might seem boring as heck, but it will teach fundamental principles of programming and logic. You have to think in terms of logic which can be hard to grasp for some people. Reading and learning how different sorts work, for example, will show you the thinking that is behind programs.

I'd start with C or C++. C# is geared towards beginners and it similar to C. Basically, you need to learn concepts now more than a specific language. Example, a IF-THEN loop compared to a WHILE loop and when to use which.

Please don't comment on languages you know nothing about.
C# is NOT geared towards beginners in any way and is NOTHING like C except syntax style.

The answer to this question really depends on what you want to do.
Do you just want to learn about programming for fun?
Do you think you may want to do it for a living?

If you want to learn the most widely used language for building commercial applications, C++ is the way to go.
If you want to learn good fundamentals of object-oriented programming or get a job working on custom business apps, Java, VB.Net, or C# are the best choices.
If you want something easy that will give you a taste of what it's like to write basic logic, learn about control structures and variables, and easily create forms with texboxes and buttons, VB6 is a good choice.

By the way, this is a repost.
More extensive discussion of the same issues can be found HERE
 
Originally posted by: gopunk
my first language was C, the last class before they switched to Java here... personally i feel i learned more than students do now about programming.

It's different learning.
VB6: I learned all about conditionals, loops, case statements, variables, and other basics of programming. This was my introduction to programming and helped me get the basics, as well as realize that I really liked programming.

Java: This is where I learned what object-oriented programming was. I learned all about the fundamentals of good OO software design. Really helped to go beyond the basics of stuff like an IF statement and really see more of the big picture of how to properly design software.

C: Learned more than I ever wanted to know about pointers, stacks, and heaps. It exposes a lot of stuff so you get a good idea of what is going on under the covers.

Assembly: Dives even deeper than C in learning about exactly how the cpu processes your instructions. Stuff that I am glad I learned, but was more than happy to get away from.

C++: Almost like a cross between C and Java. Has all the OO stuff like Java, but maintains control over things like pointers and garbage collection.
 
I know almost everyone here will disagree with me, but for just learning straight programming principles for a very beginner I still feel Pascal is probalby the most useful. I can't think of any use for a Pascal program in the real world, but it is good if you just want to learn how to program (correctly). FYI Pascal is an "ancient" programming language that has a very VB feel to it's code, but really tries to be all inclusive with ideas from all languages. It's designed purley as a "learning" language for teaching programming. Hardest part would probably be finding a good book ironically enough as most people have thrown this one out years ago.

If you want to make "real" programs, then I would say go with either C, C++ or Java.

Assembly is the extreme of low level programming. Expect to tell the CPU EXACTLY what to do. Good to use to get a real understanding of what's going on under the hood, but definatly not for a beginner.

C is a very low-level programming language. Use this if you want to learn how things work at a very low level.

C++ is basically an addition to C that adds objects. Use this if you still want to learn low-level, but also want to mess around with objects.

Java is much higher-level (well it has more abstraction at least), and will give you a lesser idea of the inner-workings, but a real solid feel for objects.

C# is Java all over again for the most part.

Don't use Visual Basic. It is real easy to learn and can make some very nice, quick apps, but you'll learn hardly anything but bad habits.
 
It's different learning.
VB6: I learned all about conditionals, loops, case statements, variables, and other basics of programming. This was my introduction to programming and helped me get the basics, as well as realize that I really liked programming.

well perhaps our curriculum was different, because all that was covered in my C course.
 
Originally posted by: gopunk
It's different learning.
VB6: I learned all about conditionals, loops, case statements, variables, and other basics of programming. This was my introduction to programming and helped me get the basics, as well as realize that I really liked programming.

well perhaps our curriculum was different, because all that was covered in my C course.

Yeah, that stuff was covered in my C class as well.
 
What kind of programming would you like to do? C is an excellent general purpose language, although it can be a bit rough to learn. Java may be a bit easier to pick up at first. You'll get more immediate satisfaction with Visual Basic, but you'll also pick up several nasty habits.

Dave
 
Ok, the majority of you seem say C and C+.

Now that I think of it, I have had a semester of Pascal in highschool. I also know html. I think that I have a decent understanding of the very basics of how programming works. I dont know how much more I should know though. I also suck at math.

Anyway, I guess I would like to create programs that help out with the little things. For instance, if im trying to organize five hundred files in a folder, and I want them all renamed in a specific pattern, (say image1, image2, image3) I would like to create a prog that would help with that. Maybe also something that would stamp a graphic label (like my name) on each picture file in a folder... other things like that. Not that I wouldn't like to expand and make more elaborate programs like a word processor or calculator. Anyway, I'd like to get my feet wet.

I could take a VB class here at college, but I dont know how much it would help me for what I want to do.
i heard its mainly for pop up windows in web applications.. But I dunno.
 
Also, pick up some books on algorithms. Might seem boring as heck, but it will teach fundamental principles of programming and logic. You have to think in terms of logic which can be hard to grasp for some people. Reading and learning how different sorts work, for example, will show you the thinking that is behind programs.

sounds like a good idea.
 
Please don't comment on languages you know nothing about.
C# is NOT geared towards beginners in any way and is NOTHING like C except syntax style.

Granted, I made a mistake in saying it's like C. It's much more like c++/java. However, according to the MS ciricculum and at least two different certified instructors I've spoken with, MS is pushing new programmers towards the C# platform. I'm not saying it's developed and geared towards beginners, but rather it's probably the best place for a new programmer to get started, and what MS recommends.

 
Originally posted by: royaldank
Please don't comment on languages you know nothing about.
C# is NOT geared towards beginners in any way and is NOTHING like C except syntax style.

Granted, I made a mistake in saying it's like C. It's much more like c++/java. However, according to the MS ciricculum and at least two different certified instructors I've spoken with, MS is pushing new programmers towards the C# platform. I'm not saying it's developed and geared towards beginners, but rather it's probably the best place for a new programmer to get started, and what MS recommends.
I haven't used C# much at all, but I'd figure that if only because of the syntax VB.NET is probably a bit easier. In terms of capabilities C# and VB.NET are almost the same, so it's six of one and a half dozen of the other.

VB6 is the most popular language in the world (I like pointing that out to the VB haters).

VB6 is a great place to start to get you going and making some programs quickly and the language is amply powerful for most people in most areas (obviously you'd not create a game in it).

Frankly I can't imagine why you'd start with a language like C. C++ would be better, but Java is probably better still because it's more nitty gritty than VB6, but simplifies a lot of things that C++ cannot.

If you have access to visual studio .net I think that learning with VB.NET would be a great starting point. It's fully OO and very powerful, yet at the same time maintains some of the simplicity that a beginner can appreciate. Otherwise probably Java.

In all honesty though it doesn't matter all that much because most people could switch between languages if they had to.

 
yeah, the curriculum was different.
I took VB6 first, then Java and C pretty much at the same time in different classes.
The rest of the more advanced classes used different languages. Some C, some Java, some VB6.

I agree that if your goal is to become a really good fundamental OO programmer, VB6 is not your best choice. But that is not a lot of people's goals. For the stuff plastick is saying he wants to do, VB6 may be the easiest place to do it. It is not a perfect language, but it is probably the easiest one to learn, and for a lot of things, it is by far the most productive way to build apps. Not everyone wants to be an enterprise software architect. Some people just want to quickly build user-friendly graphical apps that do what they are supposed to do. That is why VB6 and Access are so widely used. You can do in 5 minutes, what would take you an hour to do in Java or C or C++.

That is why I'm a big fan of dotnet. VB.Net or C# doesn't really matter. They are pretty much the same. It retains much of that ease of use and productivity by building a lot of the tedious behind the scenes code for you just like VB6 did. But it also gives you complete control over all that code if you want it. So it is far more flexible and powerful than VB6 and has all the features of a true object oriented language while still allowing you to develop quickly.

Sure, it's cool to feel superior to other's just because you write your own garbage collection code and explicitly deal with pointers, but what advantage does that really have?

Also guys, please distinguish whether you are referring to VB6 or VB.Net. It is a shame that MS decided to keep the same name when they are completely different languages except for the style of the syntax.
 
Back
Top