Posts tagged python
Python vs. PHP
0Lets quickly compare the two without wasting too much time:
#1 – Syntax
Python is it’s own funny thing, PHP resembles C/C++ very nicely. PHP wins
#2 – Speed (Time to echo “Hello World”) – 3 Runs to avoid the disk I/O.
Python:
real 0m0.027s
user 0m0.010s
sys 0m0.010s
PHP:
real 0m0.024s
user 0m0.020s
sys 0m0.000s
PHP Wins.
#3 – Looping 50000 times and printing the results.
for i in range(1, 50000):
print i
^^ is printing a newline. I googled and got this: http://stackoverflow.com/questions/4499073/printing-without-newline-print-a-prints-a-space-how-to-remove
Python is disqualified and no further tests are needed.
PHP Wins.
The reason for this post is that every single Python or Ruby on Rails developer will say with complete conviction that PHP is less than superior based on their own little understanding of programming languages as a whole and with out providing any valid arguments to justify their stance on the issue. So their informed input is nothing more than “Durrr, its too hard for me”.

Recent Comments