PHP vs Ruby vs Python

August 17, 2016 | Usman
blog-post

So, let’s pull our sleeves and join the royal rumble of programmers: PHP vs Ruby vs Python. But before we do this, here’s a little clarification. The rumble will let only one champion in the ring and it will be somewhat easy to decide as to which language to learn: php, ruby, python. Let the games begin!

1. First Round – Purpose
Float like a butterfly, sting like a bee, said Muhammad Ali. Let’s see who’d float like a butterfly and sting like a bee in the first round between php, ruby, python. When it comes to the purpose of these languages, PHP seems to be the old-school language which was designed for web development to create dynamic webpages. Ruby, to the contrary, seems to be a new-school language that is focused on making programming fun, easy and flexible. The last contender: Python was a language designed to focus more on productivity and making code reading easy. So, it seems, that Ruby stands first and then there is a tie between Python and PHP. Ruby – 1, PHP – 0 and Python – 0.

2. Second Round – Number of Languages
Php, ruby, python are all languages that are influenced by other languages. PHP is influenced by only 5 languages: C, PERL, JAVA, C++ and TCL. Ruby seems to be influenced by 8 languages: ADA, C++, CLU, DYLAN, EIFFEL, LISP, PERL and PYTHON itself. Python is also influenced by 8 languages: ABC, ALGOL 68, C, C++, ICON, JAVA, LISP and PERL. Well, this round again, tough luck PHP! Ruby – 8, Python – 8 and PHP – 5.

3. Third Round – Websites based on these languages
It’ll be interesting to see as to which websites or big-shot websites were built using these languages. We only look at the outside of a Website, we don’t know what happened inside. Let’s see. PHP has at least 10 amazing websites on its trophy table: Facebook, Friendster, Wikipedia, Udemy, Flickr, Yahoo!, iStockPhoto, Tumblr, WordPress and MailChimp. On Ruby’s trophy table there are at least 9 amazing websites: Twitter, Groupon, Shopify, Bloomberg, Indiegogo, Airbnb, SoundCloud, Zendesk and Slideshare. When it comes to Python, it has at least 7 websites to show: Google, YouTube, DropBox, Survey Monkey, Quora, Bitly and Reddit. And look who’s back in the game? PHP – 10, Ruby – 9 and Python – 7.

4. Fourth Round – Usability Meter
When it comes to programming, the usability of a language matters the most. None of the languages: Php, ruby, python can be declared 100% usable. On a scale of 1 to 10 PHP will be 6 because of its classic approach and extensive documentation. On the same scale, Ruby will be 9 because it is elegant, expressive and useful, as per the programmers. When we come to Python, it appears that it will get 7 on the same scale, because programmers who use it believe that it is the most readable programming language. So, at the end of the round, Ruby – 9, Python – 7 and PHP – 6.

5. Fifth Round – Convenient Learning
Php, ruby, python are all computer languages, and while a language’s usability is no doubt very important, convenience of learning is also one of the most important aspects. Let the round begin with the bell! So, when asked from the programmers, we got again a scale of 1 to 10 and Python overwhelmingly scores 10, PHP scores 7 and Ruby disappointingly scores only 5. Python – 10, PHP – 7 and Ruby – 5.

6. Sixth Round – Popularity
Php, ruby, python are three most popular languages, but the question is which of these three is the most popular. As per some 2011 statistics, PHP scores 6 points because of it being the old and easy to use language, Ruby scores almost 2 because it is not much easy to learn and Python scores 4 because it is usable but it employs strict indentation enforcement. So, PHP – 6, Python – 4 and Ruby – 2. Well, well, well! We are not going to calculate yet, but it seems that Ruby has almost lost the edge over its contenders!

7. Seventh Round – Word of Mouth Challenge
Relations and differences of these languages, although they are computer languages only, have some exciting ratio of being discussed among the programmers and community. This round will decide as to which language is talked about the most. As per a survey from IEEE Spectrum and if we apply the same scale of 1 to 10, it seems the Python scores 10, PHP scores 7 and Ruby scores only 4. How the might have fallen! Python – 10, PHP – 7 and Ruby – 4.

8. Eighth Round – The Job Challenge

after 8 heading

This round is about checking relations and differences of these languages when it comes to offering more jobs to its developers and learners. As per Craiglist.com and our phenomenal scale of 1 to 10, PHP scores an amazing 10, Ruby scores almost 2 and Python scores 0, yes, 0. So, PHP – 10, Ruby – 2 and Python – 0.

9. Ninth Round – Profitability
What good are Php, ruby, python if they are not profitable for the small businesses looking for developers and developers looking for jobs? Let’s check on our scale of 1 to 10. Stats given by LinkedIn and our scale show that approximately, PHP scores 10, Ruby scores 5 and Python scores 3 when it comes to job postings. However, when it comes to number of developers who use these languages, PHP scores 9, Python scores 2 and Ruby scores only 1. Now if we count the stats gathered from both scales, PHP – 19, Ruby – 5 and Python – 5.

10. Tenth Round – Need for Speed
So which one of the Php, ruby, python do you think is the fastest language in terms of lines of code and average run time? Let’s see. In case of lines of codes, if applied our scale of 1 to 10, Ruby scores 9, Python scores 8 and PHP scores 7. However, in case of average run time, PHP scores 9, Ruby scores 7 and Python scores 5. So the collective score of all these languages, for this round, will be: PHP – 16, Ruby – 16 and Python – 12.

11. Eleventh Round – Database Support
Anyone of these languages: Php, ruby, python cannot help its users without a really effective database support. While all of them have database support, since without it they would not be very useful, there are certain limitations. PHP offers extensive database support, Python also provides this support, but there are access layer limitations and Ruby also offers good database support, although not as good as PHP. So, if you ask our verdict for this round, it is a tough one, but we’d say: PHP – 7, Ruby – 6 and Python – 4.

12. Twelfth Round – Development and Updates
Apart from relations and differences of these languages, they receive developments and updates. The newer versions replace the older ones. It is not very easy to say as to which language receives developments and updates faster and which receives slower. However, based on the literature available on this topic and personal observation, we can say that PHP and Python are equally good in this respect, while Ruby’s development and updates are slower. So: PHP – 7, Python – 7 and Ruby – 4.

13. Thirteenth Round – Multiprocessing
Multitasking or multiprocessing is one of the major qualities of any computer languages and this issue is also discussed with relations and differences of these languages. While there is no data to support any comparison on that, based on personal observations, we can say that PHP and Ruby are equally good at this, while Python is kind of a backbencher in this class. So: PHP – 7, Ruby – 7 and Python – 4.

14. Fourteenth Round – Security

after 14 heading

When it comes to coding or programming e.g. making a website, security becomes an issue of paramount importance. Php, ruby, python pay special attention on the security of their projects. However, PHP is generally considered as a less secured programming languages; that is, a PHP based website would be more vulnerable to hacking as compared to Ruby or Python based websites. So: Ruby – 7, Python – 7 and PHP – 4.

15. Informational Resources
Php, ruby, python and all other computer languages have their own knowledge bases, tutorials and informational resources to help their programmers enjoy a seamless programming. However, when compared to PHP and Python, Ruby appeared to lack informational resources. Our verdict: PHP – 7, Python – 7 and Ruby – 4.
Stand up for the Champion ….. But first listen to our final verdict!
hp, ruby, python are the three most popular and in use computer languages and it was not easy to be a referee of a royal rumble of relations and differences of these languages. However, following confirmed stats, a scientific method and personal observation, and applying our scale, we have managed to give a verdict on who is the winner.
So, are you ready?
The winner of this contest and the champion of heavy weight programming is ……………
PHP —— with 118 points
Python stands second —- with 92 points
And Ruby on Rails scores only —- 89 points
Have a look at the Points Chart

Score of Each Round PHP Ruby Python
1 0 1 0
2 5 8 8
3 10 9 7
4 6 9 7
5 7 5 10
6 6 2 4
7 7 4 10
8 10 2 0
9 19 5 5
10 16 16 12
11 7 6 4
12 7 4 7
13 7 7 4
14 4 7 7
15 7 4 7
Total 118 89 92

Pie-Chart

References
www.columnfivemedia.com/work-items/infographic-code-wars-php-vs-ruby-vs-python-who-reigns-supreme
1stwebdesigner.com/php-vs-ruby-vs-python/

Leave a Reply

Your email address will not be published. Required fields are marked *


Follow Us

Shares

Dont Miss Out!

Be the first one to get the latest Industry updates,tips and tricks.

Name

"Don't worry, we won't spam you"