best language to learn

Discussion in 'Automated Trading' started by grg03002, Jul 28, 2010.

Best programming language for algo trading?

  1. Java

    14 vote(s)
  2. C#

    28 vote(s)
  3. VB

    2 vote(s)
  4. Other (please post below)

    10 vote(s)
  1. Trying to prepare myself for the future, without having done much research on the subject, I was wondering what most people think the best programming language to learn these days is. I know it used to be Java but I never really like the clunkiness of the people still think Java is good or has the world moved on to bigger and better things like C#. Thanks for the help.
  2. H2O


    I was (am) in the same position, and did some research - ended up going for Java.

    When you mention 'clunky-ness' I suggest you have a more in depth look at the new developments as Java is not as bad as it used to be.

    (Btw, I had some experience in C# before starting with Java, and I have to say I was very surprised by the similarity.)
  3. 1011011


    i'd go with any language that teaches OOP.

    why colleges teach python, fortran when there is OOP is behind me.

    stick with OOP and you'll go far kid:)

    btw, vb is not really OOP. VB.Net is though
  4. Wtf?

    Python "isn't OOP" but "VB.Net is though"?

    Learn Java because it is nearly a Lingua Franca in enterprise development. Java isn't always the best solution for a given problem, but it is never the worst, and it's a good learning language because of its verbosity / explicitness.

    C# is the better language but other than front end development most shops won't commit to using it in the critical path (read where speed matters) due to it being Windows-based. Although they're almost certainly wrong at this point; you can make WS2008 go damn fast if you know what you're doing.

    Python is a more interesting language imo (though I can't stand the syntax or GvR's inability to understand FP), but is more of a niche (CMS, web applications, and some quant applications via NumPy / SciPy).

    Don't learn C++ first. If you don't get it, it'll be very frustrating, and if you do get it, everything else sucks. This last point isn't iron-clad but if someone knows enough to argue with me they also know I'm not being literal.
  5. byteme


    This question seems to get asked on here quite frequently and occasionally ends up in a religious debate. There's no clear answer.

    There are tradeoffs which ever language you choose to learn. What is the real purpose you want to learn?

    A few random thoughts:

    - Python is probably one of the easiest to learn and most productive languages out there and contrary to what was posted earlier is plenty OO. It's a great language for beginners and experts alike who are more concerned with getting stuff done. Not so many Python jobs though if that is a factor in your decision and deciding on the right mix of tools e.g. Python version, IDE, GUI toolkit etc. can take a while to figure out for a newbie.

    - Java the language has made a few mistakes along the way but the open source ecosystem and online resources for Java is undeniably huge. There's also a vast amount of legacy code in Java at many places making it likely to stick around for a long while yet. The Google Android smart phone platform is also Java-based likely giving interest in the Java language again a little boost.

    - C# is probably the superior language now compared to Java; it has really been thought out quite well for the most part. However, you're stuck with Windows (unless you count Mono for Linux) and not so much of an open source ecosystem.

    If you're a competent programmer you can easily pick up another language when you need to, you aren't locked in for life.
  6. jeffweng


    Totally agree with the point on C++. It takes time and patience.
  7. I voted C#, but in reality (for retail trading) I tend to use C++/CLI and C++. The reason I bring up C++/CLI is because it is functionally equivalent to C# in terms of how it works with the .NET framework. In your case, however, you should consider C# if only as an introduction to .NET. The key here is .NET. The nice thing about .NET is that you can switch languages as you please -- you can write a class in Python, then inherit from it in C#, and then further inherit from that C# class in C++, all seamlessly, to the point where the languages all serve you with their respective strengths. If I'm not mistaken, even Java can run on top of .NET and play-well with other languages.

    As an example, I took old python scripts and converted them to run overtop of .NET, so now "quick and dirty" scripts are smoothly integrated into a more complex framework. If the binaries are compiled such that they are not "mixed", they can run in Linux as well.

    I generally agree with the sentiments presented on C++, but thought that I'd mention that you don't need to know the full capabilities of the language to program effectively. There are some features which are practical and others that are not quite right. As an example, you may or may not want to use RTTI, or exceptions, and so on.

    Many will disagree with my opinions, but the reason C++ is my dominant language is because of templates. People say it's difficult to debug, but I find the ability to get optimized, compile-time code with templatized-parameters essential for flexibility and taking old designs forward with new features.
  8. Oh, one thing though: C++/CLI is not as well-supported in the documentation or with the IDE integration tools, for things like web forms and WPF. This is why it becomes essential to know C# -anyway-, because some components are better suited for the C# toolset. This is why C# is a sort of must-know, even if you do end up using other languages on top of .NET.
  9. 1011011


    just admit it man, you are a python lover, ADMIT IT!! :D
    what i meant to say was, there are better programming language out there than python and fortran, in my opinion. python is quite easy to learn compared to the others. i think that's why it's offered in some college courses so that the professor can teach it without all the headaches from other languages.


    why are there so many people in favor of C# to java?

    i agree that there are faults with java as there are with other programs but i just found java to make better sense when it comes to programming real world events. if you know java, then it's not so bad learning c# and vice versa.
  10. rosy2


    i agree with byteme.
    I personally use python and R for working with non-realtime data and prototyping; most of the libraries i use are written in c or fortran. for realtime work i use java or c# is possible. When i used c++ in the past i liberally (and ignorantly) used boost and stl.

    imo, most people trying to learn programming give up within a week.
    #10     Jul 29, 2010