Why I chose Python

F*ck me. Had enough of these m*thf**kin snakes. I need a Royale with Cheese

As a newbie learning to code, the first question that you are faced with is: which programming language to choose? The purists would say it doesn’t matter. The customers don’t care if your site is coded in ASP.NET or PHP. As long as it’s solving a problem for them, it might as well have been written in Punjabi, no one gives a shit.

But this is one of those decisions that are less reversible down the road. So I wanted to make an informed decision. It came down to a choice between C#, Python, PHP or Ruby. I decided to tap on the infinite wisdom of the internet by asking questions. Its quite funny to see how quickly a shitstorm can be created with such a subjective and personal topic.





Hacker News

This was the best advice in my opinion:

Working with a language is usually a personal preference. Pick a language out of the 3 you mentioned and build something relatively simple:

  • One simple web page
  • How media(css, js) is handled in the framework
  • Connect to a database
  • One table to store your data
  • A form to save information into the table
  • Deploy it live

Do the above with all 3 of the languages and pick the one that makes your life easy. You won’t know which language fits your personality until you try them all to achieve the same task.

Decisions, decisions, decisions.

I went back to basics. My goal is to launch another startup. To do that, I needed to hunt for a technical cofounder. The personality that a technical cofounder ought to exhibit would lead him to naturally explore new languages and technology beyond his comfort zone. In this way, I generally regard C# as a safe corporate language to pursue a career in – not quite the hacker trait. From what I have read, PHP is just an inferior language to Python and Ruby. Even though a lot of people are using PHP because it is easy to get started, it seems to be easier to develop bad habits with PHP. Why jump on a bandwagon when you obviously know is broken? Granted there might be a bigger talent pool to choose from, all it means is there are more bad PHP programmers to sift through IMO.

So it came down to Python or Ruby. This is where it got a bit more arbitrary. In terms of popularity, Python and Ruby are probably the ‘in’ languages to know now. So my hacker technical cofounder would probably know either if not both. At this point, I did a quick search for number of questions tagged with Python vs. Ruby on Stackoverflow.

When I did it 1.5 months ago:

  1. Python – 43,082
  2. Ruby – 16,836

Now (FYI):

  1. Python – 48,040
  2. Ruby – 18,937

More questions asked in Python roughly means more people to answer my newbie questions down the road. So with that, I chose the snake over the gem.

20 thoughts on “Why I chose Python

  1. Pingback: Tweets that mention Why I chose Python | pragmaticstartup -- Topsy.com

  2. I think we were in the same boat. Since 2003 I have been back and forth between PHP, Ruby, and Python for side-projects while professionally having to use Java for nearly 3 years. Now I use C# and ASP.NET MVC for my 8-5 gig. And like you I feel like I can solve the problem of providing functionality via the Web in various ways. That is, with the potential learning curve ahead of you aside. There’s pros and cons to each as you know, but all I can offer is to pick one and go. Figure out what libraries you want to use: database, authentication, authorization, email, etc. and stick with it.

  3. Pingback: Change of plan: Learning Django instead of Ruby on Rails | UpsizeMyPay.com

  4. HI.

    I know PHP well, and am getting to know python. Python is sincerely awesome, I love it. “everything is an object” is very comfortable.

    PHP is good too. What I like the most about python is that most names are lowercase and under_scored, just as I code.

    I wouldn’t know what to choose if I had too, now that I’ve come to think about it 🙂 I just wanted to point out that “it seems to be easier to develop bad habits with PHP” isn’t true… and PHP’s bandwagon is working perfectly.

    The world’s most popular language must have done _something_ right…

    Congratulations on your choice.


    • I think when I made that statement 4 months ago, it was really coming from what others have said about PHP. Having been coding for 4 months now, I’ve come to realise that the main reason why PHP gets into trouble with the purists is that there are just so many ways of doing one thing — it is not that standardised. I think it became the most popular language only because its so easy to pick up! But again, I dont have much experience with PHP. I live in a Python world and so far I have little complaints 🙂 Hope you enjoy Python too!

  5. I was in a similar boat as you last year, and I also chose Python. Both Python and Ruby have a lot in common.

    When it came down to the platform I wanted to use for a recent major project that was going to have a lot complex relationships between models, a RESTful setup, and complex forms (AJAX-ified, etc), I actually ended up choosing Rails 3, and started reading up on Ruby. There are many convenience methods in Ruby by default that Rails adds on to and a great ecosystem of gems…it made for some really fast iterations, even for a beginner in Ruby. Like, just saying a Post model has_many :comments. But that’s about that…I’ve also done a project in Django and it was nice to work in Python too. I know a data guy who lives in Python but uses Rails for webdev.

    I’d personally go with Ruby at this stage, though, for rapid web development and ease of use. I was never at a loss for helpful blog entries/screencasts in either environment. Good luck!

    • Having been doing this for about 4 months now, I dare say I find Python syntax much cleaner than Ruby. So far no regrets over Python. I have since moved on to Django and I’m learning Javascript atm. Good luck with your own endeavours and thanks for dropping and leaving a comment 🙂

  6. I wondered why you didn’t considered Java. It has more questions on SO and according to Tiobe is currently the most popular language.

    It has a really great framework for creating web apps (Java EE), which is also a full stack framework (not only web stuff, but also persistence, transactions, etc).

    • Hmmmm… good question. I’m not sure about this. I think it came mainly from the fact that I didn’t read/see/hear anyone talking about Java for making web apps. It was always PHP, Python and Ruby. No fate I guess heh.

      That tiobe site is handy reference too! I didnt know about it back then.

      • This is maybe bit strange. Java is most used at server side. Many millions of companies have web application made with Java. But maybe it become so ‘normal’ that not much people talk about need to use, since it is default choice?

        Sorry, bit hard to explain, but hope you understand. I mean, like we need oxygen. No need to talk about this need, since it is so well known.

        Library of Java EE is very good. So many functionality comes out of box and really powerful!

  7. “The world’s most popular language must have done _something_ right…” How do you rank that?

    By number of posts on the net or by job offerings Java/C++ and C# are the most popular languages in the world (Java being number one).

    For languages with the more line of code in the wild, oldies like fortran or cobol would be really well placed.

    By language that are the most studied, I don’t know, but I will more bet on Java than PHP. And you’ll be surprised how many functionnal languages would be placed.

    But is the language choice really that important? I would say if you choose a popular enough language with lot of libraries for taking care of most things, does it really matter?

    Mastering a new language take years. So we have said for our startup that the right language would be the language that we all master. Simply that when creating a startup you have to many things to do, not enough time… Do you really need to learn a new language if it is not part of your core business?

    Yes your language must fit yours need too. I admit that if we focused on IA, maybe we would consider using a lisp flavour. If we were to work on a 3D game we would consider using C++…

    But here we needed a good language for the web and a good language for the business layer. Half of the existing language do just fine anyway.

    • As a newbie, I didn’t really understand the concept of ‘libraries’ plus it’s kinda hard to know how good the ecosystem is for each language. Doing the research would be quite time consuming and possible futile. Like you said, half the existing languages do just fine anyway so I just picked one and went with it.

  8. Python is a good choice & either R/P are great investments to learn.. Currently though, we in the process of porting our Ruby code across to Python. Ruby will get you to 70-80% of business requirements mark slightly faster… though, there will eventually be unknowns in your own code, Ruby’s libraries, or even pure lack of standard functionality that take allot of additional time to understand or solve before you get your project all the way to 99%. Ruby has too many libraries that do far too little – just compare SQLAlchemy to ActiveRecord or DataMapper and you’ll see what I mean. Try and figure out what the Ruby libraries are doing without knowing the whole in depth and look at the sheer number of dependencies that get downloaded… It was refreshing to work with Ruby, being so expressive and all, but we’re breathing a sigh of relief that we don’t have to understand dozens of libraries or figure out how other coders have expressed themselves just to achieve simple objectives.
    Python code looks lower level, less elegant, but Python is coherent.. and what you think it does, will be what it will do at compile time. In Ruby, you stand on the shoulders of geniuses with little guidance, the Python community has its own dogma about how things should be done and for good reason. Python is a brand and a standard, the Ruby community is protest against overly engineered languages the likes of Java – and Ruby I stress again is a great language – but all we care about is our clients & delivering code that meets business requirements as quickly as possible. The flexibility and expressiveness of Ruby just gives rise to so much extra complexity in the long run. Ruby is a sure bet for the future & that was our main justification for moving to it in the first place – they’re fixing the memory leaks, speed issues, putting more things in core and who cares about jobs if you’re a startup. But if you need to get the job done consistently (which we do TODAY) & knowing one day eventually you’ll need to patch your code, Python is the language for you.

  9. PHP, Python or Ruby.. its a real fire topic of discussion everywhere, but finally its upto the individuals… From the last 6 months I am working on PHP and I must say its really very easy to pick up. I came from C,C++ background. So for me PHP was easy to get into. But now I have jumped to the Python world. And I was wondering to prefer which of them- Python or PHP. But then slowly I am getting this point. Python syntax are really awesome, and developing web applications using Django is yet another wonderful experience.. its really a fun to work with python. I am still a beginner in python and enjoying learning it. 🙂

  10. I’ve had the same choice, but decided to go with ruby (because of rails), now i’m thinking to learn python too, just to know the difference.

  11. Pingback: Why did I choose python as my main development language ? | Tech & Wine

  12. Pingback: Language Decisions | Yan Yi

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s