Once an external project is prototyped and "proof of concept"ed they move to a faster language.
Based on what I've heard from people that work there, this is not always the case (I assume you're talking about re-writing entire applications in "something faster" after the Python prototype proves the concept). Sometimes it's not necessary to optimize the shit out of everything; to do so would be a waste of resources. One of the nice things about Python is that you can re-implement hotspots in other languages (such as C or C++) without having to rewrite the whole application (yes, I know you can do that sort of thing in other languages, too).
-- [b.belong('us') for b in bases if b.owner() == 'you']
Re:Semi-Off-Topic Python vs. Perl discussion
by
gorzek
·
· Score: 5, Informative
I can't speak for anyone else, but I did make the leap from perl to Python, and have no regrets.
I still use perl for quick-and-dirty text-processing and so forth, but Python is excellent for creating scripts you want to be able to maintain later. The syntax is sparse (compared to most other languages), so there isn't as much code to maintain. I found most of my favorite perl features were also represented (foreach, regular expressions, etc.)
People who've never spent much time with Python will gripe about the whitespace. It was never an issue for me, and I've never had problems with it.
If you plan to do any significant object-oriented programming, Python is very good for that. For procedural programs, the only edge it has over perl is readability, due to the concise syntax.
One thing to keep in mind with Python, however, is that it does NOT convert between numbers and strings automatically, while perl does. It's no big deal to cast a number as a str() or cast a string as int(), but if you don't know about it beforehand, it will get you.
From what I understand, Python is also very nice for metaprogramming, but I've never used it for that. I have used it for quick command-line utilities, GUI apps (with wxPython), and game programming. The object-oriented features are really why I prefer it over perl. They are intuitive, and you have a lot of power over how the objects behave in various circumstances.
If you have any C# experience, I've found you can port C# code to Python with only minor (mostly cosmetic) changes. (This obviously excludes using libraries written for C#, though--I was referring to the syntax of the code itself as being easily ported.)
Sorry if this explanation wasn't technical enough. I was just trying to lay out the general reasons I found a move from perl to Python relatively painless.
PyPy: a Python implementation written in Python
by
YA_Python_dev
·
· Score: 4, Informative
Python has moderately fast bytecode (google stuff could improve a lot here)
A very interesting project that aims to create a faster Python implementation is PyPy, funded by the EU, by google (with Summer of Code) and by a lot of programmers that donate their own time.
Even the Psyco guys say that the future is in PyPy!
-- There's a hidden treasure in Python 3.x: __prepare__()
Re:I love Python, but...
by
YA_Python_dev
·
· Score: 4, Informative
WxWidgets?
Good point. I think that Python + wxPython + wxGlade is a very powerful combination for clean, fast and maintainable GUI development.
If you do GUIs I suggest to try these tools: they are simple and powerful (wxPython even contains additional classes that are not present in wxWidgets).
-- There's a hidden treasure in Python 3.x: __prepare__()
Easter Egg
by
Poromenos1
·
· Score: 4, Informative
In the interpreter, do:
>>> import this
-- Send email from the afterlife! Write your e-will at Dead Man's Switch.
Re:An assumption
by
gstein
·
· Score: 5, Informative
Ha! Guido would quit in a heartbeat if you tried to make him manage people. That just isn't where he's at. He's absolutely brilliant and loves to write excellent code. Great. We're gonna let him do just that:-)
In any case: yeah, we hired him because we want him to work on Python itself. And as John says later in this thread -- about half his time.
[b.belong('us') for b in bases if b.owner() == 'you']
I can't speak for anyone else, but I did make the leap from perl to Python, and have no regrets.
I still use perl for quick-and-dirty text-processing and so forth, but Python is excellent for creating scripts you want to be able to maintain later. The syntax is sparse (compared to most other languages), so there isn't as much code to maintain. I found most of my favorite perl features were also represented (foreach, regular expressions, etc.)
People who've never spent much time with Python will gripe about the whitespace. It was never an issue for me, and I've never had problems with it.
If you plan to do any significant object-oriented programming, Python is very good for that. For procedural programs, the only edge it has over perl is readability, due to the concise syntax.
One thing to keep in mind with Python, however, is that it does NOT convert between numbers and strings automatically, while perl does. It's no big deal to cast a number as a str() or cast a string as int(), but if you don't know about it beforehand, it will get you.
From what I understand, Python is also very nice for metaprogramming, but I've never used it for that. I have used it for quick command-line utilities, GUI apps (with wxPython), and game programming. The object-oriented features are really why I prefer it over perl. They are intuitive, and you have a lot of power over how the objects behave in various circumstances.
If you have any C# experience, I've found you can port C# code to Python with only minor (mostly cosmetic) changes. (This obviously excludes using libraries written for C#, though--I was referring to the syntax of the code itself as being easily ported.)
Sorry if this explanation wasn't technical enough. I was just trying to lay out the general reasons I found a move from perl to Python relatively painless.
Check out my world simulator thingy.
A very interesting project that aims to create a faster Python implementation is PyPy, funded by the EU, by google (with Summer of Code) and by a lot of programmers that donate their own time.
Even the Psyco guys say that the future is in PyPy!
There's a hidden treasure in Python 3.x: __prepare__()
Good point. I think that Python + wxPython + wxGlade is a very powerful combination for clean, fast and maintainable GUI development.
If you do GUIs I suggest to try these tools: they are simple and powerful (wxPython even contains additional classes that are not present in wxWidgets).
There's a hidden treasure in Python 3.x: __prepare__()
In the interpreter, do:
>>> import this
Send email from the afterlife! Write your e-will at Dead Man's Switch.
Ha! Guido would quit in a heartbeat if you tried to make him manage people. That just isn't where he's at. He's absolutely brilliant and loves to write excellent code. Great. We're gonna let him do just that :-)
In any case: yeah, we hired him because we want him to work on Python itself. And as John says later in this thread -- about half his time.