Ubuntu Forums ubuntu.com - launchpad.net - ubuntu help  

Go Back   Ubuntu Forums > The Ubuntu Forum Community > Other Community Discussions > Development & Programming > Programming Talk
Register Reset Password Forum Help Forum Council Search Today's Posts Mark Forums Read

Ubuntu 9.10 is out!!!

When downloading Ubuntu 9.10 please consider using bittorrent to get your copy of Ubuntu.

The Ubuntu Developers Summit for Lucid Lynx will be held the week of 16-Nov-2009 till 20-Nov-2009 in Dallas, TX USA. Visit the the Ubuntu wiki for more information about UDS and how to participate remotely.

Programming Talk
This forum is for all programming questions.
The questions do not have to be directly related to Ubuntu and any programming language is allowed.

 
Thread Tools Display Modes
Old October 15th, 2007   #1
pmasiar
Day Old Decaf
 
Join Date: Jun 2006
Location: CT, USA
Beans: 5,268
Ubuntu 6.10 Edgy
Why to love/hate Python

To avoid shifting threads off-topic by responding to relative merits of Python (which is my preferred language), I decided to start this thread. If we can have sticky about such personal preference as IDE is, why not this, right? Selecting proper language seems to me deeper question.

Bunch of links to get context why I love Python:
  • Freedom languages vs. safety languages comparing languages in what is central: power and productivity of individual programmer, or checkpoint to secure communication between modules.
  • Why I love Python (zip) - slides by famous Java/C++ expert Bruce Eckel, author of Thinking in... series
  • "Readability counts". In other languages, (yes, Perl, I am looking at you! ) it is very hard to read code of people who use different coding standards. By making indent rules part of the standard (and btw it is normal coding practices, as you would do anyway), code of all people becomes readable. See also Myths about Indentation and howEric Raymond got scared by it at first, but "Python's use of whitespace stopped feeling unnatural after about twenty minutes" and now he prefers Python over Perl for any code above 100 lines.
  • Edit: Please do not whine about tabs and spaces. Any decent editor can convert tabs to 4 spaces for you, and if it cannot, it is good enough reason to dump it and use real editor which can. It was unusual for me to, but after couple of minutes, it is normal, and no problem at all.
  • People who need to code only occasionally prefer Python, because it is forgiving and simple to remember. And because non-professionals are 90% of the market, Python is not hype, but language for next 100 years
  • Bruce Eckel explains dynamic (latent) typing, also in artima blog, how to argue about it, and why he is over with static typing. Bruce's view about Python

This hopes be discussion on facts, not flamewar. So I try my best, but cannot be hold responsible for others. It is also possible that this will earn me ban. We will see.

Last edited by pmasiar; October 26th, 2007 at 04:26 PM.. Reason: added B.E. blogs about typing
pmasiar is offline   Reply With Quote
Old October 15th, 2007   #2
pmasiar
Day Old Decaf
 
Join Date: Jun 2006
Location: CT, USA
Beans: 5,268
Ubuntu 6.10 Edgy
Re: Why to love/hate Python

(In response from post about C
[C/Java has more resources than Python online]
One of the reasons (at least for python and for me) might be that I needed substantially less resources to get started with Python than with Java. Java is just so byzantine complicated. My "Java in a nutshell, 1.3" has 646 pages of standard format, "Python pocket reference" (2.4) has 148 pages, and pages are half the size. You need many more books to get reasonable comprehension of Java than for Python.

Last edited by pmasiar; October 15th, 2007 at 01:48 PM..
pmasiar is offline   Reply With Quote
Old October 15th, 2007   #3
AntiRush
First Cup of Ubuntu
 
Join Date: Aug 2007
Beans: 11
Re: Why to love/hate Python

Quote:
Originally Posted by pmasiar View Post
My "Java in a nutshell, 1.3" has 646 pages of standard format, "Python pocket reference" (2.4) has 148 pages, and pages are half the size.
To be fair you cannot compare those two books. Java in a Nutshell is a book meant to teach Java and goes into a lot of depth. Python Pocket reference is just that - a reference not meant to teach but to be used as a resource.

In fact, Python in a Nutshell has 654 pages.

Don't get me wrong, I use both python and java quite often and like bits of both languages. It's just not a fair comparison.
AntiRush is offline   Reply With Quote
Old October 15th, 2007   #4
pmasiar
Day Old Decaf
 
Join Date: Jun 2006
Location: CT, USA
Beans: 5,268
Ubuntu 6.10 Edgy
Re: Why to love/hate Python

Quote:
Originally Posted by AntiRush View Post
Java in a Nutshell is a book meant to teach Java and goes into a lot of depth.
My copy is "desktop quick reference", and has very little of explanation: just mentions classes and methods, one per line. Maybe you confuse it with some kind of much thicker books, like Java Bible, Shipping Weight: 3.8 pounds?

To be fair, I never seen any "pocket size" reference book for java.

P-N book has much more detailed info that J-N (I just opened in via Safari), with details and comments, multiple lines per item. Big part of P-N is just reprint of standard docs, thats why I like "pocket" book more, because lot of thought went in to compressing the info, make it more succinct, without withholding important parts.
pmasiar is offline   Reply With Quote
Old October 29th, 2008   #5
cl333r
Ubuntu Extra Shot
 
cl333r's Avatar
 
Join Date: Oct 2008
Location: White House
Beans: 359
Ubuntu 9.04 Jaunty Jackalope
Send a message via ICQ to cl333r Send a message via Skype™ to cl333r
Re: Why to love/hate Python

Quote:
Originally Posted by pmasiar View Post
(In response from post about C
[C/Java has more resources than Python online]
One of the reasons (at least for python and for me) might be that I needed substantially less resources to get started with Python than with Java. Java is just so byzantine complicated. My "Java in a nutshell, 1.3" has 646 pages of standard format, "Python pocket reference" (2.4) has 148 pages, and pages are half the size. You need many more books to get reasonable comprehension of Java than for Python.
I found a book on Python of only 74 pages, thus Python has become once again better! In fact there's a tutorial about Python on the web - it is about 2 pages, so.. since the Java book has 646 pages / 2 python pages = Python is 323 times better than Java! Can you imagine that?? It is so cool! I'm once again fascinated about Python!
Besides, I just love the fact that it's the ideal language for writing all kinds programs and libraries (really!). Linus is considering Python for the 3.0 Linux kernel implementation, because he finally got to realize that speed doesn't matter (in fact C programs are much slower and take longer to startup and consume more memory), what matters is portability and productivity.
I also love that Python has built-in cross-platform support for fast graphics with antialiasing, true-type fonts, HD audio and video and most robust support for concurrency and networking. So unlike other languages you don't have to google for compatible libraries, they're already all there waiting for you!
The potential of Python is immense! That's why I love it.

Last edited by cl333r; October 29th, 2008 at 06:30 PM..
cl333r is offline   Reply With Quote
Old October 29th, 2008   #6
LaRoza
Day Old Decaf
 
Join Date: Apr 2007
Beans: 14,805
Send a message via AIM to LaRoza Send a message via MSN to LaRoza Send a message via Yahoo to LaRoza
Re: Why to love/hate Python

Quote:
Originally Posted by cl333r View Post
I found a book on Python of only 74 pages, thus Python has become once again better! In fact there's a tutorial about Python on the web - it is about 2 pages, so.. since the Java book has 646 pages / 2 python pages = Python is 343 times better than Java! Can you imagine that?? It is so cool! I'm once again fascinated about Python!
Besides, I just love the fact that it's the ideal language for writing all kinds programs and libraries (really!). Linus is considering Python for the 3.0 Linux kernel implementation, because he finally got to realize that speed doesn't matter (in fact C programs are much slower and take longer to startup and consume more memory), what matters is portability and productivity.
I also love that Python has built-in cross-platform support for fast graphics with antialiasing, true-type fonts, HD audio and video and most robust support for concurrency and networking. So unlike other languages you don't have to google for compatible libraries, they're already all there waiting for you!
The potential of Python is immense! That's why I love it.
I'm not sure what is post is about. Is it sarcasm, ignorance, or a joke?

No one claims Python is suitable for all things (for instance, Python and many of its modules are written in C)
LaRoza is offline   Reply With Quote
Old October 29th, 2008   #7
curvedinfinity
Way Too Much Ubuntu
 
curvedinfinity's Avatar
 
Join Date: Jun 2006
Beans: 319
Send a message via AIM to curvedinfinity Send a message via MSN to curvedinfinity
Re: Why to love/hate Python

I really love python from the language point of view. Its clean, lovely to write, and has a million well made libraries.

My big gripe with it is that its distribution template is not friendly to windows users. -- Its hard to distribute a Python app to Windows because you first have to get users to install Python. The extra step isn't a big deal for developers, but its a killer for the "basic" end user.

Sure, you can embed python in a compiled app, but that defeats the purpose of using an interpreted language.

... Considering all of that, I use Python in every application I make for myself and don't want to distribute. Its simply the best language from a productivity point of view.
__________________
"Simplicity is the ultimate sophistication." - Leonardo da Vinci
curvedinfinity is offline   Reply With Quote
Old October 29th, 2008   #8
jimi_hendrix
May the Ubuntu Be With You!
 
jimi_hendrix's Avatar
 
Join Date: Jul 2008
Beans: 1,695
Re: Why to love/hate Python

i find i actually code worse in python than a more C like language...but i realize how easy it is to learn and its grate for beginners
__________________
blog
caruso R.I.P. best dog ever

jimi_hendrix is offline   Reply With Quote
Old October 29th, 2008   #9
LaRoza
Day Old Decaf
 
Join Date: Apr 2007
Beans: 14,805
Send a message via AIM to LaRoza Send a message via MSN to LaRoza Send a message via Yahoo to LaRoza
Re: Why to love/hate Python

Quote:
Originally Posted by curvedinfinity View Post
I really love python from the language point of view. Its clean, lovely to write, and has a million well made libraries.

My big gripe with it is that its distribution template is not friendly to windows users. -- Its hard to distribute a Python app to Windows because you first have to get users to install Python. The extra step isn't a big deal for developers, but its a killer for the "basic" end user.

Sure, you can embed python in a compiled app, but that defeats the purpose of using an interpreted language.

... Considering all of that, I use Python in every application I make for myself and don't want to distribute. Its simply the best language from a productivity point of view.
You can bundle the installer with it. Also, you can easily distribute Python apps in Linux (which is the platform that matters).

Also, installing ActivePython is very familiar to Windows users (although it would be a pain from a Linux point of view, all that clicking...)
LaRoza is offline   Reply With Quote
Old October 29th, 2008   #10
curvedinfinity
Way Too Much Ubuntu
 
curvedinfinity's Avatar
 
Join Date: Jun 2006
Beans: 319
Send a message via AIM to curvedinfinity Send a message via MSN to curvedinfinity
Re: Why to love/hate Python

Quote:
Originally Posted by LaRoza View Post
...in Linux (which is the platform that matters).
That's pretty zealous, don't you think? Linux is gaining market share, but the success hasn't come from exclaiming to everyone that they had it wrong all along. Linux's success has come from the idea that everyone, regardless of platform, ideology, race, or social status is important. 99.9% of the world only views technology as a means to an end, not something important in itself, like our subculture does. Thus, in terms of supporting these people, its important to make processes as simple and short as possible.

But I'll tell you what, in terms of Linux, I completely agree that Python apps are even easier to deal with than compiled apps.
__________________
"Simplicity is the ultimate sophistication." - Leonardo da Vinci
curvedinfinity is offline   Reply With Quote

Bookmarks

Tags
flamewar, python

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 07:40 PM.


vBulletin ©2000 - 2009, Jelsoft Enterprises Ltd. Ubuntu Logo, Ubuntu and Canonical © Canonical Ltd. Tango Icons © Tango Desktop Project. lingonberry