DEV Community

Abanoub Hanna
Abanoub Hanna

Posted on • Originally published at abanoubhanna.com

Go or Python ? Which language is used more in production software?

I think that Go is better than Python. And that's my own opinion. But I was wondering if people are using Go or Python for their production software in the real world. I want to get statistics of production software to compare and understand the real world.

Source of statistics

In a previous post, I used Homebrew as the source of statistics about apps written in each programming language. Homebrew is a package manager for MacOS and Linux distros.

Homebrew provides a json file of the index of all packages and apps in Homebrew Core Formulae.

So I created a simple CLI application written in Go to use that updated JSON file to count the apps using a specific programming language.

Statistics by gobrew

language June 2 July 1
Go 988 998
Python 777 783
Cython 11 11

According to statistics, Go is used for more production software than Python.

Why Go is used more than Python ?

comparison Go Python / Cython
compilation speed very fast Python: not compiled, Cython: very slow
runtime performance very fast Python: slow, Cython: good
concurrency support great bad
libraries & frameworks good enough huge
readability good good

As you can see, Go checks all factors mentioned, but Python is great at things and bad at other things. Programming languages are just tools, so, overall, I personally choose Go every time as the better tool to get the job done. Most software developers choose Go over Python as you can conclude from the statistics above.

I hope you enjoyed reading this post as much as I enjoyed writing it. If you know a person who can benefit from this information, send them a link of this post. If you want to get notified about new posts, follow me on YouTube, Twitter (x), LinkedIn, and GitHub.

Top comments (3)

Collapse
 
kwnaidoo profile image
Kevin Naidoo

I have quite a few micro-services running in Golang. For web services, Golang is a brilliant choice if you want to squeeze performance out of your infrastructure without dropping to C++/C or Rust.

You get that Python-like dev experience with Go, and speed is not too far from Rust/C.

Python is great for machine learning, small maintenance scripts, and web apps in general. You can use caching to get decent enough performance, so there's not always a need for Go in this space.

Use both, they are both awesome and powerful. I am also a fan of PHP.

Collapse
 
oggo profile image
oggo

100% agree! Python is brilliant and very easy to use, but Go is awesome. I only don't like the name :-D

Collapse
 
ismailbayram profile image
İsmail Bayram

it depends on your necessities.
if you want to develop robust applications use go, but if you want to develop fast, use python