• Martin Thoma
  • Home
  • Categories
  • Tags
  • Archives
  • Support me

What is the best programming language?

Contents

  • Bash
    • Example
  • Python
  • Java
  • C++
  • C
  • See also
  • Matlab

There is no such thing as a best programming language. Sorry about that, I've just thought it would be a catchy title. I would rather choose my tools after I know the problem I have to solve.

Some programming languages are very good at some tasks. I don't know any that is very good at every task.

This comic illustrates what I mean:

A fair test - comic - illustration - cartoon - caricature
A fair test

Bash

The bash is great for tiny tasks where other programs are involved.

Example

Resizing all jpg-images in a given folder to a maximum resolution of 1600x1600 while maintaining the aspect ratio:

for i in *.JPG;do convert "$i" -resize 1600x1600 "${i%.JPG}-resized.jpg"; done

See Converting Files with Linux for more examples.

Python

Python does a incredibly well job for small problems. I don't have experience with big projects, but some have been done using Python (see list below). Python is dynamically typed, offers a lot of functions out of the box and is easy to learn and understand. You might argue that Python is executable Pseudocode as it is so easy to read. Additionally, it offers a very neat library for math functions with NumPy.

Examples of Python-Code in applications include:

  • PDF malware analysis
  • BitTorrent
  • My ProjectEuler Snippets ☺
  • Scripting within an application:
    • GIMP
    • Blender
  • Websites and Services:
    • GNU Mailman
    • Reddit
    • Trac

Java

Java is used in the economy for simple, but huge tasks. It is static and strong typed, has some widely used coding convetions, is easy to learn and has a big library.

Here are some examples for programs written in Java:

  • Mars Rovers (source)
  • BitTorrent client Vuze
  • Sites that have URLs like "*.do", "*.jsp" and "...servlet..." are most likely written in Java.
  • Games:
    • FreeCol
    • Minecraft

C++

C++ is easy to write and blazing-fast. See Performance of Matrix multiplication in Python, Java and C++.

Some projects done in C++ are:

  • NASA flight software: 300k LOC (source)
  • Chrome, Firefox
  • Games:
    • Cube 2: Sauerbraten
    • UFO: Alien Invasion
    • The Battle for Wesnoth
    • OpenClonk (Repository)
    • OpenLierox (Repository)
    • Secret Maryo Chronicles (Repository)

C

See Is C still used? and a comment from Linus Torvalds.

Programs done with C:

  • Freeserf (Repository)

See also

  • 5 Ways to Tell Which Programming Languages are Most Popular
  • OpenGameClones

Matlab

What is MATLAB good for? Why is it so used by universities? When is it better than Python?

Do you know some more programs that are famous and should be in these lists? Preferably with an open repository?


Published

Nov 3, 2012
by Martin Thoma

Category

Code

Tags

  • C 23
  • Java 36
  • Programming 52
  • Python 141

Contact

  • Martin Thoma - A blog about Code, the Web and Cyberculture
  • E-mail subscription
  • RSS-Feed
  • Privacy/Datenschutzerklärung
  • Impressum
  • Powered by Pelican. Theme: Elegant by Talha Mansoor