![]() |
FAQ: Which Language Is The Best To Learn.
(can someone with the relevant powers make this sticky?)
This is a question which comes up time and time again. To advoid people asking the same question again and again, I decided to make list of languages and what they are good for. There is no best language to learn. They are all different and used for different reasons (hence, so many of them). This is as much of an exhustive list as I can think of. If you want to add to the list, be my guest: Assembly (ASM): You'll typically want to use MASM or NASM for this (compilers). Assembly is a pnumonic form of the core 0s and 1s the CPU directly understands to carry out instructions. It requires alot of instructions, typically, to do anything obviously useful. The use of assembly is virtually obsolete now, what with higher-level language compiler technology so good nowadays, there is no need to use assembly (a new C super-compiler exists, apparently, that even knocks hand-written+optimised assembly into a hat!). You would want to use assembly for very efficient code (because the instructions allow complete manipulation of the CPU). What is typically used, are Assembly directives in a C program (so you can write the bulk in C - alot easier - and the bits that need to be optimised, in assembly). Although good higher-level-language compilers do exist, they are very expensive (so this C/ASM approach is still an option). Good only for very complex projects, due to the difficultly in learning and using assembly. C: This is a higher-level-language than ASM. This means, that each instruction does more (so less has to be written, and it's easier to debug). C has become the de-facto standard for ALOT of companies. This reason is historical (and that, as a result, more people know C than any other language), and not necessarily a good one. Learning C is good if you want to write something on a CV you'll know be useful for a lot of computing jobs. C, however, allows alot of dirty tricks and has poor memory management. This basically means, its very easy to insert a bug which exists only because the program has allowed an action to take place that shouldn't be allowed to happen. The latter means a thing known as "memory leak" happens frequently, which is where over time the program fails to deallocate memory it used. The syntax of C also makes it a hard language to get into C. However, C is both very fast and very flexible (its possible to use the "dirty tricks" for clever programming). Both free ANSI compilers, and paid for Borland and Microsoft compilers are typically used to compile C. (Integrated into Unix. Therefore very easy to write a C program for, say, Linux) C++: Same as C, but with OOP added (among other things). OOP (object orientented programming) is a very big trait used in programming today, especially for large projects. It is a useful thing to know, and hence alot of people skip to learning C++, without bothering to learn C first. Same pros+cons as C apply for C++. The only thing to remember is, C programs are typically faster than C++ programs. But this is due to C++ programs usually containg objects. On the flip-side, the use of OOP allows for programs that would be tricky to do in C, and not likely be as efficient. Ada95: Very strict language. Similar syntax to C (well, closer still to Pascal, but i don't really know anything about that language). It forces good programming technique, by inforcing strict rules on what you can and can't program. This takes away some of the flexibility, that would be visible in a C program; this isn't a problem, however, since problems are worked around, and are more likely to work. It is used for safety-critical systems, where it is a necessity the program doesn't crash (e.g. the software used to control a nuclear-power-plant). For this reason, its not often learnt by the layman, but is still good to consider, if you think you might want to extra discipline to help in learning good programming practise. Free compilers can be found on the net easily. Contains OOP. (infact, is the only language officially supporting OOP.) Typically not as fast as C, but apparently, frequently beats similar C++ code in speed. Visual Basic: OK - my knowledge of VB is fundamental at best, but it is supposedly a very easy language to learn. It also used in macros in Office apps, but also as a variant called VBA or Visual Basic For Applications. VBA is the language to learn if you want to integrate and manipulate Microsoft Office Documents and MS Access Databases. Contains OOP. Another variant of this (Simialr to how Java and Javascript are) is ASP or Active Server Pages. ASP: Like PHP, this is a scripting language and is not compiled prior to being run. It is interpreted at run time. This generally causes a performance hit because the code is being interpreted as it is "read" into memory by the server when the page is requested. This is object oriented. All variables are of type VARIANT which again causes a hit because they are not specifically declared as a "string" or "integer" etc. ASP is a dynamic language that allows dynamic content,database driven applications and websites to be made much like PHP. ASP has the ability to call ActiveX components that perform specicif functions based on parameters passed to the ActiveX Object that is instantiated when called. ActiveX components can be written in C/C++ , VB or .NET. ASP can only be run on Microsoft IIS though there is an emulator for *nix, it is very slow. Java: Cross-compatable code. Compile once, and it should work on any computer with a Virtual Machine. Used everywhere, mobile phones, PDAs, Web-sites; the list goes on. It is useful, because you can learn one language and be able to code for your PC, but also for your mobile phone. SImilar syntax to C. Supports OOP. Not as fast as the aformentioned languages, due to having to run on a VM. However, my argument for that is: I suspect there are very few people, who want to program, that will ever write code that absolutely requires that extra bit of speed. If your program is too slow, its because you've written it badly, not because the language is a bit slower. Free and Pay-for compilers available. PHP: A back-end language for web-applications and services. It allows dynamic content for a web page (e.g. a forum, you click the same link, but the page content will vary depending on whats on the database). Supports OOP, and has alot of nifty features that allow for some pretty powerful code. Using the Zen pre-processor (i don't think it counts a fully fledged compiler) can be faster than all the other currently available back-end languages. Its free, and requires no compilation (since it runs natively on the server's software). JavaScript: A cut down, and slightly modified version of Java. Used for web-page wizardry (e.g. when you choose an item from a drop-down menu in a form, and the form changes slightly: thats JavaScript doing that). This allows the site to be dynamic once its downloaded to your browser (rather than generate a dynamic page). Basically, anything that wants to move on your site (unless its done in Flash or is an animation file) has to be done in JS. Its pretty essential to learn, therefore, if you plan on making web-sites. HTML: Hyper-Text-Markup-Language This is the "language required" to build the body of any web page. This is an absolute must if you plan on getting into web-design. Though HTML isn't really a language, it is mostly for formatting web pages for display purposes. XML: Extensible-Markup-Language This is pretty cool to learn. It can be used in web pages, but can be used in any program really. It (much like HTML, which are basically the same thing. HTML can be expressed in XML.) is parsed, meaning the syntax of the language is checked, and any semantic meaning behind a tarticular tag results in code being executed. (It's no great surprise, the parser is typically written in C). The domain for use of this is fairly specific, I would say. Learn, only if you have to (or want to). (Eg someone says, oh, yes, XML would be good for that.) Others: Prolog, Lisp: These are declerative types of language. (Excepting XML and HTML, all languages mentioned so far are imperative). The main difference is an imperative language describes how to do something, a declerative describes what do to. It can be difficult at first to get your head round, but it allows for very powerful (it not for consumer programs) programs. Prolog is typically used to write AI. Don't get excited, however, and think that you should learn Prolog. It requires a shed load of mathematical knowledge to use correctly, and even then is only used for AI you almost certainly won't be writting. "AI" for games, for example, is just a series of clever tricks (and hence, written in C usually). The "AI" that prolog writes is WAY to complex for a normal computer to handle alongside graphics, sound, etc etc. Free compilers can be found for both. |
FORTRAN is still alive and cooking.
FORTRAN (Formula Translation): {definition is taken from http://www.yourdictionary.com/}: A high-level programming language for problems that can be expressed algebraically, used mainly in mathematics, science, and engineering. A good source for information and links to other useful sites can be found at: http://www.nsc.liu.se/~boein/fortran.html |
Quote:
Quote:
|
reason that compiler can sometimes do betetr optimizations, is the sheer number of instructions for any given processors. Would take the palest gremling form intel to list em all :P
|
Say again, I just dont' see how compielr that can't possibly optimize as well, the only way I can see it beating the Assembly is for a big program where optimization is hard and "functions" (just calls :)) start to be used to save space.
|
Ya tahts what i mean. Try optimizing 10 trillion liens of ASM. the sheer voluem of the task is why compiler can do it better, as you will eventualy make mistakes.
Its posible to beat one the compiler, if you have that much time to do it in a large application. |
You could probably write you own functions and make it nicer and possibly beat C because they are in assembly and not C which isn't a space issue, but for large apps C is the only way to go =/
|
Agreed.
|
when it comes to that extremely nice C++ compiler that does that "knocks hand-written+optimised assembly into a hat", can i ask ya what compiler it is??? thanks!
|
Turns code into binary, it actually turns into Assembly and then binary... For example gcc -S will create an Assembly file of your code.
|
hes asking what compiler will make better then hand written assembler code.
I dont know personaly, and i doubt it can be done on a oen for one basis <ie take two programs of equal size, and hand written one will be better, although will have taken longer> |
Hi guys.
Ummmm, firstly: sorry for the delay in replying; haven't been on the boards for a while :D OK - so quick responses: firstly masm and nasm ARE compilers. Both of these provide pre-processing commands, and syntax checking. The process of converting pnemonics into binary also comes under compilation. There are two primary parts to compilation: front-end and back-end Front-end is lexical and syntactic checking. Backend is optimisation and code-generation. Whilst there is no optimisation possible when writing ins assembly, all the other parts take place. Also - with regards to ASM coding (sorry I skipped out most of your conversation, just hoped I picked up on the gist :)) vs C etc coding. Firstly, no. High-end compilers now-a-days will knock hand assembly into a hat. The primary reason for this, is that they can have a much more global perspective of the system. Even your basic app could easily have 1 mil instructions in assembly. The sheer volume of code, and inter-relations between eg. far/near jumping, code-reorganisation, memory optimisation etc etc etc etc (and goodness me, even more etc) means that the human mind really cant take all this into consideration. At most you would be given a module to code, of maybe 100 to 500 thousand lines, and then, even with abstraction of code, optimisations between modules are possible. And a final point, not many people both understand the hardware system AND the OS system that they code for SO well, that they could optimise for it completely. Im not saying that on a small scale, with say a few thousand lines of code *only*, a human couldn't match (or **maybe** beat) a high-end compiler, but you wont find many projects where this is a reality, and software now-a-days just doenst come in packages that small. But I supose I should clarify (also in response to who asked which compilers achieve this). There IS a difference in compilers. That's why you might pay a few hundred for MS's Visual compilers (actually the GNU compilers, which are free, are quite respectiable for this class of compiler) aint gonna match to a enterprise IBM compiler costing 10s of thousands of pounds/dollars/euros. ;) |
Quote:
Compilers translate high-level languages into machine code and assemblers convert assembly language programs into machine code. |
Re: FAQ: Which Language Is The Best To Learn.
I don't want to sound stupid but isn't this a "right tool for the right job". I mean most of the high order languages are made because they wanted somthing special to be done in an easier way. If I want cross compatibility I won't use lisp or one of the several different assembly languages, but java, etc.
Also there are several different Assembly languages, because it's part of the instruction sets (the interface between the processor and the software basically). The Intel processors and the Mips Processors have different Assembler languages is an example. Also I didn't see Perl, Python, Scheme, C# which all have their different uses |
Re: FAQ: Which Language Is The Best To Learn.
No, compilation (when we are talking about it, in the domain of traditonal HLLs, not your bytecode language or interpreted) is the process of compiling non-machine code, into machine code binary. The fact that the pnemonics of Assembly have a 1-1 relationship with binary representations, is a side-issue. Besides, NASM has macro support, which is certainly not a 1-1 relationship. The compilation process in NASM compilers involve syntax checking, and actual output of binary code. That is a front ot back code generation process. That is what compilation is. But, we argue over symantics :D
Further, to the last response. Correct, languages are a best-tool for the job. That's what I was hoping to illustrate here with my post. It certianly isn't a comprehensive list (and at the time, when it was compiled, C# and the .Net structure was a very new baby indeed. I didn't know enough about it to include it) However, firstly.... I suspose I should clarify some points some more: You mention that you wouldn't use Lisp for cross-compatibilty. However, that would be a very good reason to use Lisp (or Python,or TCL, or Perl, etc) because they are "intrepreted languages", which means that they there is no "compilation" (see above :)), merely a instruction to an underlying intrepeter to call some function. Java, is a different beast again. Java isn't intrepeted like this. Java actually creates what is known as "byte-code", a mid-way version of assembly, which can be abstractly thought of as the native instructions of the "virtual machine" it runs on. It is this VM layer between the byte-code (which will always be the same) and the actual binary generated by the VM from the byte-code, that is platform specific, that creates the cross-compatability of Java. C# is basically the same notion, although the "VM" in this case is the .Net framework and stack implementations. Umm, oh yes, and scheme is an object-oriented version of Lisp. It is effectively the same language. I really need to edit my original post.... but last time I was on the boards, I couldnt.. maybe because its "sticky". Oh, and finally, with regards to your assembly point (just because I feel like a pedantic annoying know-it-all, and work is boring atm :D), assembly IS the entire instruction set of the PU (processor unit) of a system. You are absolutely correct, assembly differs from architecture to architechture. But it's not the interface between the hardware and software. Assembly is the 1-1 pnemonic mapping of the instructions that result in execution of the binary values that have been read in from the pipeline of the PU. It is actually the lowest abstraction of software possible on a machine (well, ok, the actual binary itself it, but, meh). Enough from me..... :/ |
Re: FAQ: Which Language Is The Best To Learn.
Blah... i cant find the edit button after a few minutes.....
But i meant to say "exhustive list" not "comprehensive list"..... |
my head hurts.
but interresting stuff from what i understood. |
Re: FAQ: Which Language Is The Best To Learn.
|
Re: FAQ: Which Language Is The Best To Learn.
And it is ...
Quote:
|
Re: FAQ: Which Language Is The Best To Learn.
I didn't see C# on the list.
|
Re: FAQ: Which Language Is The Best To Learn.
Which of these languages would be the best to introduce myself to programming?
|
Re: FAQ: Which Language Is The Best To Learn.
Quote:
|
Re: FAQ: Which Language Is The Best To Learn.
Quote:
|
Re: FAQ: Which Language Is The Best To Learn.
I'm biased towards VB.NET. If you learn VB.NET , then moving to the web using the same language is pretty easy (ASP.NET using VB.NET).
www.gotdotnet.com www.devcity.com www.4guysfromrolla.com books: Programming Visual Basic.NET by Francesco Balena ISBN 0735620598 |
Re: FAQ: Which Language Is The Best To Learn.
ill check those sites out, ty. Is VB.NET based on Visual Basic? I know the fundamentals of VB, wondering if they'll help or not.
Also do u no any good books/webpages for Java? |
Re: FAQ: Which Language Is The Best To Learn.
With all due respect Major sir you just f my head up . I really want to learn a program language. But I'm having a hard time trying to figure out wear to start. Could you please email me a good website that can get me starting in the right the direction or maybe you can help me . Just remeber what was your starting point . And then teach me geekfoo so some day I shall be young geekmaster.
|
Re: FAQ: Which Language Is The Best To Learn.
Honestly, I started out by buying ASP3.0 Beginner by Wrox Press and just started reading. After a few chapters I started doing. It doesn't come by osmosis so you have to get into it and follow an example or two.
What kind of things do you want to build? |
Re: FAQ: Which Language Is The Best To Learn.
I only know basic coding in HTML. If I want to create an interactive website (i.e. create my own forum, guestbook, the works), what should I learn first? Which one doesn't require me to have knowledge of any language except HTML (and maybe English :p )?
|
Re: FAQ: Which Language Is The Best To Learn.
PHP,ASP or ASP.NET
ASP.NET is by far the most powerful of the 3 but is quite different in the sense that it's not a scripting language like PHP or ASP are. |
Re: FAQ: Which Language Is The Best To Learn.
Quote:
|
Re: FAQ: Which Language Is The Best To Learn.
[This is a sticky, so this isn't exactly bumping...]
I think PHP would be the best as well. I'm currently learning it. I'm finding that if you can understand how some JavaScript (or C++; they do have some similar methods) works, you can understand PHP. The problem with me is that PHP and MySQL (databases) tend to go together, so I'm actually trying to learn 2 at once... Once I do learn though, I'll be able to finally create my own forum since MySQL is required to store user info/preferences, threads/topics, etc... |
Re: FAQ: Which Language Is The Best To Learn.
It might be the best to learn but I find Liberty BASIC to be the easiest to learn.
|
Re: FAQ: Which Language Is The Best To Learn.
hi i believe that C an C++ are the best langauges to learn 'coz a C programmer is not going to die for next 100 years and a lot of languages can perform simple tasks but C is somthing tht is able to perform the most complicated tasks .
|
Re: FAQ: Which Language Is The Best To Learn.
There is no best language. You would not code a web page in C++ or Qbasic. Different languages are there for different reasons. If I were to recomend a language for someone to learn I would want to know a few things first.
1.) Do you know any other language? 2.) Are you familar with OOP Object oriented Programing 3.) What is it you want to do? That is do you want to make stand alone GUI applications? Make web pages? Make command line scripts? The hot thing right now 12/12/2005 is C++, | many vendors Java Enterprise, |Sun Microsystems, few others make compilers .Net platform | Micro$oft PHP |http://php.net SQL data bases | http://mysql.com , http://www.microsoft.com/sql/default.mspx , http://www.postgresql.org/ , C and C++ | http://gcc.gnu.org/, http://www.borland.com/downloads/download_cbuilder.html, Do not confuse C/C++ with micr$ofts Visual C++. They are not the same. You also have your markup languages such as SMIL, XML, HTML, XHTML, SGML http://xml.coverpages.org/sgml.html (not for meer mortals) So to answer the question... There is no single best language. As a matter of fact once you get into programming you will often find you NEED more than one to get the project done. Most video games these days are C++ with some assembly thrown in for speed. There are also MANY more things going on as well. |
Re: FAQ: Which Language Is The Best To Learn.
Guess, Le4rner is right, there is no specific prog. language to learn, "Different Programming Languages for Different Uses", My, advice go out, decide what you want to program, get the language that does it well and master it!, then if you change your mind, it is now possible for you to move on. just keep this on mind. you can learn all things but can't do it all at the same time. best to the geeks:)
|
Re: FAQ: Which Language Is The Best To Learn.
Le4rner,
I just wanted to applaud your having pointed out that ANSI C/C++ are miles away from Microsoft's versions... write "hello world" in MN VC++ and you have 1.5 megs worth of crap added to it ;-) I would also have to add that learning programming within a visual development environment is generally a mistake, for one spends more time learning about the tool and less about the language... if one gets the tool taken away, he or she finds him or herself paralyzed. Development environments such as Visual Studio are limited in what they can do for you in the beginning, as the machine-generated code is not very good. Just my opinion... |
Re: FAQ: Which Language Is The Best To Learn.
The best language to learn is the language that will fit to your need at the moment. This involves consideration of the following, among others:
1. Task needed to be done -- Does it involve gui, api, or just plain text on screen? Are there lots of computations that need to be optimized? So on.. 2. Learning curve for the programmer -- When a new language is considered in favor of #1 then how long will it take you(the programmer) to learn the *necessary* detail of the language to do the task. Note that at this point, it is important to know what you want to do first before you can clearly pinpoint what is necessary. Plan ahead, that is. Again, the best language to learn depends on the necessity and time. |
Re: FAQ: Which Language Is The Best To Learn.
i want to learn java, where do i start?
|
Re: FAQ: Which Language Is The Best To Learn.
The reason you don't see C# listed here is because it is a musical note. It is musically the same as D flat.
|
Re: FAQ: Which Language Is The Best To Learn.
Personally, I think Visual Basic is a good place to start. It's a good intro to programming. It's what I was taught my freshman year of college.
I also think C++ is a good language to have. It's very versitile, and once you know the basics to programming, you can learn other languages from it. I learned assembly and just because I learned the instruction set to the 8085, doesn't mean I can't program in another language. You learn the basics and you can adapt those basics to other languages. Right now I"m using Python(python.org, not python.com) which is very similar to Perl. It was easy for me to pick up because it's similar to C++, it's kinda like lazy C++. I don't know HTML or PHP very well, but if I look at it, for the most part I can figure out what it is trying to do because I have programming experience. |
| All times are GMT -5. The time now is 14:24. |
Powered by vBulletin® Version 3.8.3
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Ad Management by RedTyger