Question:
What are the reasons behind learning a Programming Language?
2011-05-25 03:26:57 UTC
I'm 16 and thinking of learning C++ followed by Java (I already have books on C++ available and someone who can help me).

I want to know the capabilities of the language, how future-proof it is an what it's uses are to an enthusiast.

Thanks :)
Six answers:
2011-05-25 11:53:13 UTC
Learn C++. I would recommend you learn C first though, in my experience I found it hard to learn C++, then tried C and found it so easy and actually enjoyable, I returned to C++ after learning C and I found it so much easier to learn. Pointers are one of the hardest concepts to grasp in C++ and learning C first simplified the process for me.



Capabilities:

C is a lower level language than C++ and is mainly used for utility programs, command line tools and for developing memory intensive programs that mainly operate without a GUI or with a minimal UI. The C language in itself is incredibly small and can be easily learnt with speed. It is only the Packages and Extensions to the language to add functionality which make it large. If your intention is to learn C++ though you don't need to learn all of hat, just the core Language.



C++ is a fully fledged Object Oriented Language but still provides all the functionality of C through legacy features. You can use most C code inside a C++ application without problem.





Future-proof:

C was developed in 1973. It is 38 years old and it is still alive and used today and there is no sign of it going anywhere. Arguably it isn't compatible with Object Oriented Programming but despite popular misconceptions OOP can't solve every problem.



C++ was developed in 1983. It is 28 years old and it too is still used extensively and in some areas of development e.g. Games Development it is almost used exclusively. There is no sign of it going anywhere either. C++ is compatible with OOP as that was its purpose and remains one of, if not the most powerful OO programming language(s).





Uses:

Most modern Operating Systems still use C [some in conjunction with C++] for the development of their Kernel [the very core of the OS]. The UNIX shell which is also used by Linux and OS X is almost entirely C. A variant of C known as Objective C is also the language of choice by Apple both for its OS X programs and for iOS apps. iPhone and iPod Touch apps are written in Objective C.



C++ as already mentioned is heavily used in Gaming most major PC and PS3 games are written in C++. Xbox uses C# which is a Microsoft specialised implementation of Java [in essence, not literally]. C++ is used for many applications.

Your web browser [Firefox or IE] is written in C++. Right up to their latest distributions [Firefox 4 and IE 10 respectively] and there are no plans to change languages any time soon.





References:

Any C Programmer worth their weight learnt the language through this book [1]. It was written by the authors of the Language itself so you can't get a better insight to the language than that.



I won't suggest C++ reading materials as you already said you had books on it. You don't have to learn C first you can go straight for C++ but like I said I would advise you to try as I found it a great help



EDIT: [correcting other answers]



- C is not a hard language to learn. The language itself is simple.

- C++ is more advanced than Java.

- Java is slower because Java was developed with multiple safety nets to make developing programs easier for beginners - arguably many of these safety nets do more harm than good in terms of performance

- C++ has the same wealth of tools utilities and support as Java if you are willing to invest time and effort.

- C++ is not meant for Rapid Action Development - it is meant for programmers who know what they are doing, and what they want to do



At the end of the day you shouldn't believe anyone when they say how hard or how easy a language is to learn - not even me. How easy or difficult it will be for you is personal and will depend on your learning style your ability to grasp concepts and the time and effort you want to bestow on the learning process.



C++ takes time to learn - time most amateur programmers aren't willing to invest which is why so many people say it's hard to learn - like anything with time and effort you can understand it. There is nothing inherent about C++ that makes it more difficult than any other language to learn.
PleaseInsertACoin
2011-05-25 04:21:35 UTC
C++ is arguably one of the most widely spread programming languages (though the same could be said over Java).



Unlike the stereotype, C++ is not really any harder to learn than most other languages, however it comes with many details that are not immediately obvious to a beginner. If you've got someone to help, that is pretty much the best thing that can happen to you (provided said person really has an in depth understanding of the language himself - otherwise it's probably going to do more harm than good).



Unlike what the person above said, C++ provides all features you'd expect from a modern programming language. Downsides of C++ come mostly from oddities remaining in the language due to the backwards compatibility to C.



Java is also a good language, IMHO it doesn't really matter which one you start with- C++ and Java are similar enough.
Berni
2011-05-25 03:55:07 UTC
C++ should be called a 2.5th generation language as it is better than Assembly yet too hard to be considered a truly 3rd generation language. I've heard there is a new updated version coming out soon. It is a very poor choice for beginners as its data structures encourage bad habits. Java was created with these shortcomings in mind so there are no pointers in Java and there is a String data structure.



Strengths & Future-proof: C++ is used as an alternate to Assembly for programming large applications such as operating systems, fast apps such as games and all sorts of machine-level manipulation such as system utilities. Since there has been no contender in this arena for decades, there is a good chance it will survive for the foreseeable future.



Java's weakness is that it usually compiles to run inside a virtual machine, making it slow yet portable. It is a futuristic language compared to C++. Let me say if C++ is an ape then Java is homo sapiens :-)



There have been some native compilers for Java and I've heard they make its speed comparable to C++. The good news in all this is that if you learn C++, you'll find learning Java a breeze as Java has a very similar syntax yet supports a lot of functionality and programmer productivity packages that C++ programmers can only dream of.
2011-05-25 03:35:13 UTC
C + + is a language that you develop the ability to think, help you get good decisions in the short term. Besides, it is a common programming language and in principle much like all other programming languages​​. You can create applications in Visual Basic, Java and many other languages ​​using your what you learned in C + +. Also you can program the microcontrollers and microprocessors (which you can do all sorts of useful devices at very low prices).
2016-04-30 14:26:24 UTC
That's a very broad question and depending on what kind of programming you're interested in will help you select the kind of language you want to learn. There are literally dozens of programming languages out there suited for all sorts of purposes. Some languages aren't technically "programming" by the strictest definition, such as HTML and JavaScript but we'll include those in our discussions. Programming essentially starts with a design. "What do you want this program to do?" From there, the design gets broken down into small tasks. These tasks are then implemented in the program where they work together to produce the desired result. A program is implemented through "source code." This is what the programmer actually types at his terminal at 3AM while he's jittering because he drank 3 gallons of coffee. The source code is then fed into a special program called a compiler that looks at the source code and converts it into machine code that the processor can use. (There's also another program called a linker, but that's a more advanced topic not relevant to this answer) Alternatively some programs are never compiled, but rather interpreted by a special code interpreter. A common example of this is web pages using HTML. The web browser interprets the HTML text and displays it on the screen. No compiling is ever done. The advantage of this is that the program is guaranteed to work regardless of which computer it is run on (e.g. Macintosh, Windows, Linux, etc) The disadvantage is that interpreted programs tend to be less efficient than compiled programs. That being said, let's contine on to a discussion of popular programming languages in use today: C/C++: I grouped the C and C++ programming languages together because they are nearly identical in syntax and perform very similarly. The major difference is that C++ supports "classes" whereas C does not. (Classes are an advanced topic not relevant to this answer) Most modern applications today use C/C++ as their programming language. Java: A hybrid programming laguage, Java was designed to have its applications run on any Java-Enabled computer, but still maintain the performance benefits of compiled code. It does this by compiling the code halfway into something called "bytecodes" that are highly optimized, but still cross-platform. From there, the Java Runtime Environment(tm) compiles the code the rest of the way for its particular processor. HTML: Not technically a programming language, HTML stands for HyperText Markup Language. It was specifically designed for creating web pages. Today, HTML can support 3rd Party plugins (e.g. Quicktime videos), Cascading Style Sheets, JavaScript (not to be confused with Java), and more. Assembly: A low-level compiled programming language. Assembly gives direct commands to the processor and its registers. As a result, programming in assembly requires an intimate knowledge of the CPU. Programming in assembly is very tedious, much like building a sand castle one grain at a time. However, because it allows the programmer to directly control the processor, it allows for extremely high efficiency applications. Assembly code is generally reserved for portions of operating systems which require a very fine degree of control. There are many many many more programming languages in use today. If you like, you may be interested in reading about C#, Visual Basic, Python, Perl, Fortran, BASIC, and Pascal to name a few.
question asker
2011-05-25 09:30:20 UTC
If you're learning C++ you should definitely check out the Qt framework (especially if you're building GUI applications). It's very cool. You could say that Qt Javifies C++ (almost).


This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.
Loading...