This is an archive of past discussions. Do not edit the contents of this page. If you wish to start a new discussion or revive an old one, please do so on the current talk page. |
Archive 1 | Archive 2 | Archive 3 | → | Archive 5 |
Python is described in "it transparently supports bignum arithmetic". "bignum" is defined as encompasing both arbitrarily large integers and rational numbers. Python does not yet provide for rational number arithmetic.
I don't believe Python supports Functional programming, as in Prolog or somesuch. It supports function-based programming... meaning that your program is just composed of functions not organized into classes and objects. I have gotten the two confused in the past, and I suspect that this is what happened here.
Or does Python really support functional programming? Is there some add-on package that allows this? I wasn't aware of one. -- ansible
Yes, Python really does have some built-in functional programming features such as "map()", "filter()", "reduce()" and a somewhat limited "lambda", although I've read that Guido van Rossum now regrets including these features in the language. As a more readable and "Pythonic" alternative, "list comprehensions" were more recently introduced into the language and can often be used instead of the older functional programming constructs.
I do not think Python is 'strongly influenced' by Perl. In fact the design philosophy is diametrically opposite in some senses. pasokan
I'm not sure if we should say that Python is strongly typed. It provides a lot of implicit conversions (eg, between numeric types, between string types) and makes common use of functions accepting any one of a group of related types (any sequence, or any 'file-like object'). It doesn't make it easy to derive a new type from an old one without making it compatible (eg, you can't easily make a new integer type which isn't comparable with the standard Integer). Matthew Woodcraft
Hfastedge -- Please take more care when editing this article. Your point that Python is dynamically typed has already been integrated with the article and does not need to be repeated. A few of your other points were erroneous or misleading, which is why they were removed. Please take the time to understand this and do not simply add them again.
Your statement that Python programs are "interpreted, not compiled" is simply false. Python -- like Java and Perl -- is a bytecode-compiled language. Compilation is implicit before execution of uncompiled scripts, which is why a new Python user might not have noticed its existence. However, it's there; it's how Python works; and yes, compiler errors are distinct from runtime errors. Compiled Python files have the extension .pyc, or .pyo if optimized. If you've never seen one, you haven't used Python for very long.
Python is a dynamically typed language, because that is how it is designed. It is neither a mistake nor an accident. Talking about this as if it is something suitable to "change" with a "paradigm shift" is not talking about Python, it is talking about your opinion of dynamic vs. static typing.
Your claims regarding "massive projects" vs. "rapid prototyping" are ill-advised in the light of the many massive projects that have been written quite successfully in dynamically typed languages (including Python). If you would like to discuss advantages and disadvantages that critics perceive in static and dynamic type-systems, you might want to do so on the pages for those subjects.
In addition, I suggest strongly that you study the writing style of other Wikipedia articles, as it will help you to integrate your work more fully with an article. You might particularly want to watch your use of links -- introducing a link with "here is:" is rough anywhere on the Web. Namespaces are not created lightly. Also, needless indentation turning a Wiki document into a piece of flat text are not desirable. -- FOo
Hfastedge 09:05 18 Jun 2003 (UTC)
A fine general article as the the features of Python, but (unless I'm to tired to notice it) there doesn't seem to be a mention of the uses of Python as a glue language, either with C/C++ using a SWIG interface or with Java in the form of Jython. The stuff about Python vs. Java, whilst being a fair enough comparison, maybe misleads into thinking that their use is in direct competition, whereas they can play complementary roles in development. I'd be tempted to make these comments but I'm (a) rather too new to wikipedia to chance it and (b) way too tired at the moment. But I think this stuff is worth mentioning. sobekhotep
From what I read, Python has inheritance but no access control (public, private,...). Can someone ellaborate on OOP in Python? -- Error
Python 2.3 now comes with an un-ordered collection type, the set. I too will refrain from adding to the Python Wiki page as I cannot match the high standard of the article. - Paddy3118
Added link to Aspect oriented programming for the types of programming styles that Python offers. See this article or this google search for support. Hyakugei
Now this is a beautifully written page with very high technical value. I am afraid though that there is a little bit of personal oppinion in the philosophy section (and that seems almost normal :) By judging the comments my point of view was confirmed. For what seems to be the technical influence between Perl and Python there is IMHO more than enough evidence to claim a relationship. When it comes to the point of view of the users I think it might be a good idea to outline that there are two groups of people, myself being part of the second one, and I would love if this second group could be mentioned in this article. My idea would be to write something as follows:
"It is interesting to notice that given the aforementioned similarities [between Perl and Python] there are some who consider them very much different in style and quality. Some others like both languages for their qualities and would rather prefer to see the two languages evolve together".
But great work, really great work.
Robert Dober robert.dober@free.fr 195.167.202.147 16:39, 1 Jun 2004 (UTC)
Hi, Pythoners. Over at object oriented programming, I wrote the following:
Python and Ruby are relatively recent languages that were built from the ground up with OOP...
I have recently read some conflicting statements about object based functionality only being added in version 2.2. Over at python.org, I was't able to find anything that specifically mentioned whether or not object orientation was in the language from the beginning. Would anyone know? Thanks. AdmN 21:16, 26 Aug 2004 (UTC)
Shouldn't be Parrot, the common framework for Python and Perl be mentioned ?
Maybe it's an attempt of Perl to devour Python, maybe it's just a joke... However, it received attention of several important programmers. For instance, Perl creator.
Hgfernan 22:38, 4 Sep 2004 (UTC)
I think that if we are talking about Philosopy of Python we should mention Tim Peters Pythonic Thesis I wrote a quick page on him and his Python Thesis, perapsh this should be included too?
An anon user removed all but the outermost braces from the example of the factorial function written in C. I have reverted it back for the time being because I'm not sure the anon's version is correct, or clear, whereas the pre-edit version is both.
Is it correct?
The statement blocks from which the anon removed the braces were blocks of one statement each. Since I have not written C code in a decade, my knowledge is rusty; I believe this may be technically correct, that you may omit the braces from a statement block only if there's only one statement in the block. However, I am not sure on this point.
Is it clear?
Even if the code as the anon edited it is compiler-correct, it is misleading; the entire point of the comparison is that Python uses indentation, as opposed to punctuation, which is what C uses in every case except single-statement blocks, where it becomes optional.
What should we do about it?
In the short term, I have reverted, as previously mentioned. However, in the long term, we should perhaps decide between three alternatives (assuming that omission of braces is in fact legal in C for single-statement blocks):
The code as it was before the anon edit. The disadvantage is that it does not show the one instance in C where a programmer may choose to omit the braces. The advantage is that it more accurately reflects the general practices of C. Since the article is about Python and not C, the disadvantages don't strike me as too significant in this case.
The code as it was after the anon edit. The disadvantage is that it does not show one possible way a C programmer might format their code in the one case where they have a choice. The advantage is that it is more accurate, at least in terms of how a C programmer might format (many programmers choose to format consistently in the style that is always allowed, even when they language offers a choice.)
A different example that requires multiple-statement blocks. The disadvantage is that it would require careful selection of a new example. The advantage is that it would not be an artificial example. This doesn't strike me as too much of an advantage; don't hundreds of computer text books demonstrate basic principles by showing the bubble sort, despite the notorious inefficiency of the bubble sort?
I think on the whole my recommendation is for the first alternative, but if anyone disagrees, please bring up the issue here.
-- Antaeus Feldspar 18:26, 21 Sep 2004 (UTC)
I have not made this change in the main article in order that someone more familiar with Python can confirm the correctness of the example. -- Phil | Talk 12:48, Sep 22, 2004 (UTC)
int factorial(int x) { if (x == 0) { return 1; } else { return x * factorial(x-1); } }
is syntactically equivalent to:
int factorial(int x) { if (x == 0) { return 1; } else { return x * factorial(x-1); } }
def factorial(x): if x == 0: return 1 else: return x * factorial(x-1)
is not equivalent to:
def factorial(x): if x == 0: return 1 else: return x * factorial(x-1)
if (x == 0) x = 100; y = 100; /* Syntactically legal, but misleading indentation; y is assigned the value 100 regardless of the condition */
above):
if (x == 0) x = 100; y = 100;
if x == 0: x = 100 y = 100 # No confusion possible, y only assigned the value 100 if the x == 0 condition was true
if x == 0: x = 100 y = 100 # y is assigned regardless of the x == 0 condition outcome
- Just want to point out that this is a rather poor way to implement a factorial function. The number of recursions is very quickly exceded.
Feldspar, I am not convinced. Please supply better proof. 216.153.214.94 03:49, 5 Nov 2004 (UTC)
Certainly, a better way to show the operation of the language would be
fac = lambda x: reduce(lambda a,b: a*b, xrange(1, x+1))
;)
For the record, this performs pretty much identically (I timed both with a couple of numbers between 10 and 100000) to
def fac(x): product = 1 for n in xrange(1, x+1): product *= n return product
-- Fredrik | talk 04:32, 5 Nov 2004 (UTC)
Although its only an example for indentation, the code could be simplified. There is not point in the "if else" in this case, its a one branch conditional.
Factorial function in C:
int factorial(int x) { if (x == 0) return 1; return x * factorial(x - 1); }
Factorial function in Python:
def factorial(x): if x == 0: return 1 return x * factorial(x - 1)
This can be "simplified" to:
def factorial(x): return x == 0 and 1 or x * factorial(x - 1)
But this code is less readable. Its not clear what is the exit condition, you have to "parse" the line to understand it.
It is possible that my last edit didn't improve the article in all respects. Comments would be welcome.
Three lines were removed; I'll motivate why here:
Hmm, there are some confusing, misleading or plain wrong statements in this article:
(I know should fix the article; but if I don't get around to finishing that, at least my objections are recorded.)
I think it's about time that we move this page to Python. 9 out of Google's top 10 hits for the word "python" is to the language and the other one is for Monty Python. The real life snake just isn't interesting enough. Eric B. and Rakim 07:07, 12 Jan 2005 (UTC)
As big a fan as I am, Python the language just does not have the prominence that would justify it displacing the very thing it was (indirectly) named after. -- Antaeus Feldspar 19:52, 13 Jan 2005 (UTC)
What is that supposed to mean? - Fredrik | talk 02:43, 14 Jan 2005 (UTC)
Imagine this:
def foo(): """Hi foo()"""
"docstringing" it out:
""" def foo(): """Hi foo()""" """
The compiler will throw a SyntaxError at "Hi foo()" because it thinks that is the code. Ok badly phrased, but the essence is that commenting using docstrings is bad. :) Eric B. and Rakim 02:55, 14 Jan 2005 (UTC)
/* int function() { /* Returns 0*/ return 0; } */
The reference to Oz I had introduced a few months ago as a multi-paradigm language (like Python & Perl) has been removed and I can't see any discussion on the reason for this. Oz is considered by many as the most multi-paradigm language in existence today. Oz is the language used within the new book Concepts, Techniques, and Models of Computer Programming, MIT press. This book is already considered a classic, and possibly the equivalent of Structure and Interpretation of Computer Programs, by Sussman & Abelsson. See Lambda The Ultimate site for many references to this book. I therefore bring the reference to Oz back in the Python page.
The explanation of parameter passing in Python needs work. It is a common confusion to say that Python passes values by reference (even among experienced Pythonistas), but GvR explains it correctly in his tutorial. Basically, all parameters are passed by value, but object values are references. The reason this becomes an issue is that mutable objects appear to be passed by reference. Non-mutable objects such as numbers and strings don't show this behavior. What doesn't seem to be commonly understood is that the same issue shows up with assignment:
It's also a bit awkward to say that Python variables "contain" values. Python variables actually bind names to values which isn't the same thing. Looked at that way, you can see that after y = x, y and x are different names bound to the same value. Mutating the object bound to x will naturally affect the object bound to y -- it's the same object. That list isn't contained in two different places, it just has two different names.-- Quale 21:01, 7 Mar 2005 (UTC)
I moved Python (disambiguation) to Python and Python to Python (snake) to make the Wikipedia easier to navigate. A large number of the python links were about the language and this will reduce the average number of clicks to get around. I know some people here would have liked this article to become the main Python page, but I think that's a bit computer programmer centric and would simply reverse the problem. I followed the example of Cobra.
Still, the existing links to Python that are about the language should be fixed to point directly to this article. Daniel Quinlan 09:40, Mar 8, 2005 (UTC)
Sayeth the article:
In what sense are continuations "functional"? ISTM they are imperative, in the sense that they are a facility for manipulating control flow. Neilc 12:50, 1 Apr 2005 (UTC)
if not (shouldGOTOLine500): # line 470 furble(x) # line 480 quimble(y) # line 490 foobaz(x,y) # line 500
This looks simpler:
def add_and_print_maker(x): def temp(y): print x, "+", y, "=", x+y return temp
Than:
def add_and_print_maker(x): def temp(y): print "%d + %d = %d" % (x, y, x+y) return temp
since when wikipedia does free ad to company. or is PyAlaMode a necessity to someone. PLEASE REMOVE THAT and put PyGTK or PyQT or whatever PyFOO u want, or just remove [cause you already have 2 exmaples nad it's enough]
This is an archive of past discussions. Do not edit the contents of this page. If you wish to start a new discussion or revive an old one, please do so on the current talk page. |
Archive 1 | Archive 2 | Archive 3 | → | Archive 5 |
Python is described in "it transparently supports bignum arithmetic". "bignum" is defined as encompasing both arbitrarily large integers and rational numbers. Python does not yet provide for rational number arithmetic.
I don't believe Python supports Functional programming, as in Prolog or somesuch. It supports function-based programming... meaning that your program is just composed of functions not organized into classes and objects. I have gotten the two confused in the past, and I suspect that this is what happened here.
Or does Python really support functional programming? Is there some add-on package that allows this? I wasn't aware of one. -- ansible
Yes, Python really does have some built-in functional programming features such as "map()", "filter()", "reduce()" and a somewhat limited "lambda", although I've read that Guido van Rossum now regrets including these features in the language. As a more readable and "Pythonic" alternative, "list comprehensions" were more recently introduced into the language and can often be used instead of the older functional programming constructs.
I do not think Python is 'strongly influenced' by Perl. In fact the design philosophy is diametrically opposite in some senses. pasokan
I'm not sure if we should say that Python is strongly typed. It provides a lot of implicit conversions (eg, between numeric types, between string types) and makes common use of functions accepting any one of a group of related types (any sequence, or any 'file-like object'). It doesn't make it easy to derive a new type from an old one without making it compatible (eg, you can't easily make a new integer type which isn't comparable with the standard Integer). Matthew Woodcraft
Hfastedge -- Please take more care when editing this article. Your point that Python is dynamically typed has already been integrated with the article and does not need to be repeated. A few of your other points were erroneous or misleading, which is why they were removed. Please take the time to understand this and do not simply add them again.
Your statement that Python programs are "interpreted, not compiled" is simply false. Python -- like Java and Perl -- is a bytecode-compiled language. Compilation is implicit before execution of uncompiled scripts, which is why a new Python user might not have noticed its existence. However, it's there; it's how Python works; and yes, compiler errors are distinct from runtime errors. Compiled Python files have the extension .pyc, or .pyo if optimized. If you've never seen one, you haven't used Python for very long.
Python is a dynamically typed language, because that is how it is designed. It is neither a mistake nor an accident. Talking about this as if it is something suitable to "change" with a "paradigm shift" is not talking about Python, it is talking about your opinion of dynamic vs. static typing.
Your claims regarding "massive projects" vs. "rapid prototyping" are ill-advised in the light of the many massive projects that have been written quite successfully in dynamically typed languages (including Python). If you would like to discuss advantages and disadvantages that critics perceive in static and dynamic type-systems, you might want to do so on the pages for those subjects.
In addition, I suggest strongly that you study the writing style of other Wikipedia articles, as it will help you to integrate your work more fully with an article. You might particularly want to watch your use of links -- introducing a link with "here is:" is rough anywhere on the Web. Namespaces are not created lightly. Also, needless indentation turning a Wiki document into a piece of flat text are not desirable. -- FOo
Hfastedge 09:05 18 Jun 2003 (UTC)
A fine general article as the the features of Python, but (unless I'm to tired to notice it) there doesn't seem to be a mention of the uses of Python as a glue language, either with C/C++ using a SWIG interface or with Java in the form of Jython. The stuff about Python vs. Java, whilst being a fair enough comparison, maybe misleads into thinking that their use is in direct competition, whereas they can play complementary roles in development. I'd be tempted to make these comments but I'm (a) rather too new to wikipedia to chance it and (b) way too tired at the moment. But I think this stuff is worth mentioning. sobekhotep
From what I read, Python has inheritance but no access control (public, private,...). Can someone ellaborate on OOP in Python? -- Error
Python 2.3 now comes with an un-ordered collection type, the set. I too will refrain from adding to the Python Wiki page as I cannot match the high standard of the article. - Paddy3118
Added link to Aspect oriented programming for the types of programming styles that Python offers. See this article or this google search for support. Hyakugei
Now this is a beautifully written page with very high technical value. I am afraid though that there is a little bit of personal oppinion in the philosophy section (and that seems almost normal :) By judging the comments my point of view was confirmed. For what seems to be the technical influence between Perl and Python there is IMHO more than enough evidence to claim a relationship. When it comes to the point of view of the users I think it might be a good idea to outline that there are two groups of people, myself being part of the second one, and I would love if this second group could be mentioned in this article. My idea would be to write something as follows:
"It is interesting to notice that given the aforementioned similarities [between Perl and Python] there are some who consider them very much different in style and quality. Some others like both languages for their qualities and would rather prefer to see the two languages evolve together".
But great work, really great work.
Robert Dober robert.dober@free.fr 195.167.202.147 16:39, 1 Jun 2004 (UTC)
Hi, Pythoners. Over at object oriented programming, I wrote the following:
Python and Ruby are relatively recent languages that were built from the ground up with OOP...
I have recently read some conflicting statements about object based functionality only being added in version 2.2. Over at python.org, I was't able to find anything that specifically mentioned whether or not object orientation was in the language from the beginning. Would anyone know? Thanks. AdmN 21:16, 26 Aug 2004 (UTC)
Shouldn't be Parrot, the common framework for Python and Perl be mentioned ?
Maybe it's an attempt of Perl to devour Python, maybe it's just a joke... However, it received attention of several important programmers. For instance, Perl creator.
Hgfernan 22:38, 4 Sep 2004 (UTC)
I think that if we are talking about Philosopy of Python we should mention Tim Peters Pythonic Thesis I wrote a quick page on him and his Python Thesis, perapsh this should be included too?
An anon user removed all but the outermost braces from the example of the factorial function written in C. I have reverted it back for the time being because I'm not sure the anon's version is correct, or clear, whereas the pre-edit version is both.
Is it correct?
The statement blocks from which the anon removed the braces were blocks of one statement each. Since I have not written C code in a decade, my knowledge is rusty; I believe this may be technically correct, that you may omit the braces from a statement block only if there's only one statement in the block. However, I am not sure on this point.
Is it clear?
Even if the code as the anon edited it is compiler-correct, it is misleading; the entire point of the comparison is that Python uses indentation, as opposed to punctuation, which is what C uses in every case except single-statement blocks, where it becomes optional.
What should we do about it?
In the short term, I have reverted, as previously mentioned. However, in the long term, we should perhaps decide between three alternatives (assuming that omission of braces is in fact legal in C for single-statement blocks):
The code as it was before the anon edit. The disadvantage is that it does not show the one instance in C where a programmer may choose to omit the braces. The advantage is that it more accurately reflects the general practices of C. Since the article is about Python and not C, the disadvantages don't strike me as too significant in this case.
The code as it was after the anon edit. The disadvantage is that it does not show one possible way a C programmer might format their code in the one case where they have a choice. The advantage is that it is more accurate, at least in terms of how a C programmer might format (many programmers choose to format consistently in the style that is always allowed, even when they language offers a choice.)
A different example that requires multiple-statement blocks. The disadvantage is that it would require careful selection of a new example. The advantage is that it would not be an artificial example. This doesn't strike me as too much of an advantage; don't hundreds of computer text books demonstrate basic principles by showing the bubble sort, despite the notorious inefficiency of the bubble sort?
I think on the whole my recommendation is for the first alternative, but if anyone disagrees, please bring up the issue here.
-- Antaeus Feldspar 18:26, 21 Sep 2004 (UTC)
I have not made this change in the main article in order that someone more familiar with Python can confirm the correctness of the example. -- Phil | Talk 12:48, Sep 22, 2004 (UTC)
int factorial(int x) { if (x == 0) { return 1; } else { return x * factorial(x-1); } }
is syntactically equivalent to:
int factorial(int x) { if (x == 0) { return 1; } else { return x * factorial(x-1); } }
def factorial(x): if x == 0: return 1 else: return x * factorial(x-1)
is not equivalent to:
def factorial(x): if x == 0: return 1 else: return x * factorial(x-1)
if (x == 0) x = 100; y = 100; /* Syntactically legal, but misleading indentation; y is assigned the value 100 regardless of the condition */
above):
if (x == 0) x = 100; y = 100;
if x == 0: x = 100 y = 100 # No confusion possible, y only assigned the value 100 if the x == 0 condition was true
if x == 0: x = 100 y = 100 # y is assigned regardless of the x == 0 condition outcome
- Just want to point out that this is a rather poor way to implement a factorial function. The number of recursions is very quickly exceded.
Feldspar, I am not convinced. Please supply better proof. 216.153.214.94 03:49, 5 Nov 2004 (UTC)
Certainly, a better way to show the operation of the language would be
fac = lambda x: reduce(lambda a,b: a*b, xrange(1, x+1))
;)
For the record, this performs pretty much identically (I timed both with a couple of numbers between 10 and 100000) to
def fac(x): product = 1 for n in xrange(1, x+1): product *= n return product
-- Fredrik | talk 04:32, 5 Nov 2004 (UTC)
Although its only an example for indentation, the code could be simplified. There is not point in the "if else" in this case, its a one branch conditional.
Factorial function in C:
int factorial(int x) { if (x == 0) return 1; return x * factorial(x - 1); }
Factorial function in Python:
def factorial(x): if x == 0: return 1 return x * factorial(x - 1)
This can be "simplified" to:
def factorial(x): return x == 0 and 1 or x * factorial(x - 1)
But this code is less readable. Its not clear what is the exit condition, you have to "parse" the line to understand it.
It is possible that my last edit didn't improve the article in all respects. Comments would be welcome.
Three lines were removed; I'll motivate why here:
Hmm, there are some confusing, misleading or plain wrong statements in this article:
(I know should fix the article; but if I don't get around to finishing that, at least my objections are recorded.)
I think it's about time that we move this page to Python. 9 out of Google's top 10 hits for the word "python" is to the language and the other one is for Monty Python. The real life snake just isn't interesting enough. Eric B. and Rakim 07:07, 12 Jan 2005 (UTC)
As big a fan as I am, Python the language just does not have the prominence that would justify it displacing the very thing it was (indirectly) named after. -- Antaeus Feldspar 19:52, 13 Jan 2005 (UTC)
What is that supposed to mean? - Fredrik | talk 02:43, 14 Jan 2005 (UTC)
Imagine this:
def foo(): """Hi foo()"""
"docstringing" it out:
""" def foo(): """Hi foo()""" """
The compiler will throw a SyntaxError at "Hi foo()" because it thinks that is the code. Ok badly phrased, but the essence is that commenting using docstrings is bad. :) Eric B. and Rakim 02:55, 14 Jan 2005 (UTC)
/* int function() { /* Returns 0*/ return 0; } */
The reference to Oz I had introduced a few months ago as a multi-paradigm language (like Python & Perl) has been removed and I can't see any discussion on the reason for this. Oz is considered by many as the most multi-paradigm language in existence today. Oz is the language used within the new book Concepts, Techniques, and Models of Computer Programming, MIT press. This book is already considered a classic, and possibly the equivalent of Structure and Interpretation of Computer Programs, by Sussman & Abelsson. See Lambda The Ultimate site for many references to this book. I therefore bring the reference to Oz back in the Python page.
The explanation of parameter passing in Python needs work. It is a common confusion to say that Python passes values by reference (even among experienced Pythonistas), but GvR explains it correctly in his tutorial. Basically, all parameters are passed by value, but object values are references. The reason this becomes an issue is that mutable objects appear to be passed by reference. Non-mutable objects such as numbers and strings don't show this behavior. What doesn't seem to be commonly understood is that the same issue shows up with assignment:
It's also a bit awkward to say that Python variables "contain" values. Python variables actually bind names to values which isn't the same thing. Looked at that way, you can see that after y = x, y and x are different names bound to the same value. Mutating the object bound to x will naturally affect the object bound to y -- it's the same object. That list isn't contained in two different places, it just has two different names.-- Quale 21:01, 7 Mar 2005 (UTC)
I moved Python (disambiguation) to Python and Python to Python (snake) to make the Wikipedia easier to navigate. A large number of the python links were about the language and this will reduce the average number of clicks to get around. I know some people here would have liked this article to become the main Python page, but I think that's a bit computer programmer centric and would simply reverse the problem. I followed the example of Cobra.
Still, the existing links to Python that are about the language should be fixed to point directly to this article. Daniel Quinlan 09:40, Mar 8, 2005 (UTC)
Sayeth the article:
In what sense are continuations "functional"? ISTM they are imperative, in the sense that they are a facility for manipulating control flow. Neilc 12:50, 1 Apr 2005 (UTC)
if not (shouldGOTOLine500): # line 470 furble(x) # line 480 quimble(y) # line 490 foobaz(x,y) # line 500
This looks simpler:
def add_and_print_maker(x): def temp(y): print x, "+", y, "=", x+y return temp
Than:
def add_and_print_maker(x): def temp(y): print "%d + %d = %d" % (x, y, x+y) return temp
since when wikipedia does free ad to company. or is PyAlaMode a necessity to someone. PLEASE REMOVE THAT and put PyGTK or PyQT or whatever PyFOO u want, or just remove [cause you already have 2 exmaples nad it's enough]