Hubris connects Ruby to Haskell, will there be such a connection between Python and Haskell?

2010-02-16 Thread Casey Hawthorne
Hubris connects Ruby to Haskell, will there be such a connection between Python and Haskell? -- Regards, Casey -- http://mail.python.org/mailman/listinfo/python-list

Interesting talk on Python vs. Ruby and how he would like Python to have just a bit more syntactic flexibility.

2010-02-16 Thread Casey Hawthorne
Interesting talk on Python vs. Ruby and how he would like Python to have just a bit more syntactic flexibility. http://blog.extracheese.org/2010/02/python-vs-ruby-a-battle-to-the-death.html -- Regards, Casey -- http://mail.python.org/mailman/listinfo/python-list

Re: What does Guido want in a GUI toolkit for Python?

2009-06-27 Thread Casey Hawthorne
So, what *does* Guido want in a GUI toolkit for Python? I saw a talk by a school teacher on pyFLTK: GUI programming made easy. On another note: I#: Groovy makes it easy to tie into the Java Swing GUI, so if Python could do that, with the added complication being the user would need a JVM. --

I'm intrigued that Python has some functional constructions in the language.

2009-05-08 Thread Casey Hawthorne
I'm intrigued that Python has some functional constructions in the language. Would it be possible to more clearly separate the pure code (without side effects) from the impure code (that deals with state changes, I/O, etc.), so that the pure code could be compiled and have aggressive functional

Re: Complete frustration

2009-05-08 Thread Casey Hawthorne
On Fri, 08 May 2009 14:18:44 -0700, Emile van Sebille em...@fenx.com wrote: On 5/8/2009 1:45 PM hellcats said... I have Python2.5 installed on Windows XP. Whenever I double click on a something.pyw file, IDLE launches and opens something.pyw in the editor. I would prefer to actually *RUN* the

Can't one collect twitts and twits in any language?

2009-04-04 Thread Casey Hawthorne
:) -- Regards, Casey -- http://mail.python.org/mailman/listinfo/python-list

Is there anyway Vpython and pyODE can be made to work with newer versions of Python 2.6.1 etc. without a lot of changes to source code?

2009-01-23 Thread Casey Hawthorne
Is there anyway Vpython and pyODE can be made to work with newer versions of Python 2.6.1 etc. without a lot of changes to source code? I suppose I'm thinking of an extra layer of indirection, which might slow things down to much. :) -- Regards, Casey --

Re: [ANN] Update to Python Quick Reference Card (for Python 2.4) (v0.67)

2007-05-02 Thread Casey Hawthorne
PC-cillin flagged this as a dangerous web site. Laurent Pointal [EMAIL PROTECTED] wrote: PQRC (Python Quick Reference Card) is a condensed documentation for Python and its main libraries, targetting production of printed quick http://www.limsi.fr/Individu/pointal/python/pqrc/ -- Regards,

Re: a better solution for GUI in python

2007-03-11 Thread Casey Hawthorne
For a browser interface have you thought of Ajax and possibly WPF/E? http://en.wikipedia.org/wiki/AJAX http://en.wikipedia.org/wiki/Windows_Presentation_Foundation -- Regards, Casey -- http://mail.python.org/mailman/listinfo/python-list

PyPy with a smaller PVM for the full Python?

2006-09-10 Thread Casey Hawthorne
Currently PyPy is working toward compiling to C a restricted subset of Python, called RPython. Would it be possible for PyPy to compile the full subset of Python by also using a lot smaller version of the PVM (Python Virtual Machine) to go with the compiled code? So, the user would be running the

Can Your Programming Language Do This? Joel on functional programming and briefly on anonymous functions!

2006-08-03 Thread Casey Hawthorne
Can Your Programming Language Do This? Joel on functional programming and briefly on anonymous functions! http://www.joelonsoftware.com/items/2006/08/01.html -- Regards, Casey -- http://mail.python.org/mailman/listinfo/python-list

Re: Fastest Way To Loop Through Every Pixel

2006-07-27 Thread Casey Hawthorne
Have you tried PIL? (Python Imaging Library) Chaos [EMAIL PROTECTED] wrote: As my first attempt to loop through every pixel of an image, I used for thisY in range(0, thisHeight): for thisX in range(0, thisWidth): #Actions here for Pixel thisX, thisY But it

Since there was talk of if-then-else not being allowed in lambda expressions, the following is from Dive into Python

2006-07-20 Thread Casey Hawthorne
Since there was talk of if-then-else not being allowed in lambda expressions, the following is from Dive into Python The and-or conditional expression trick from page 41 of Dive into Python Wrap the arguments in lists and then take the first element. a = b = second (1 and [a] or [b])[0] ''

For Large Dictionaries Could One Use Separate Dictionaries Where Each Dictionary Covers an Interval of the Input Range?

2006-05-16 Thread Casey Hawthorne
For Large Dictionaries Could One Use Separate Dictionaries Where Each Dictionary Covers an Interval of the Input Range? You would need to know something of the input range and its uniformity! Self-balancing between dictionaries for separate dictionaries? -- Regards, Casey --

Is the only way to connect Python and Lua through a C interface?

2006-05-16 Thread Casey Hawthorne
Is the only way to connect Python and Lua through a C interface? -- Regards, Casey -- http://mail.python.org/mailman/listinfo/python-list

Tail Call Optimization Decorator?

2006-05-13 Thread Casey Hawthorne
Tail Call Optimization and Recursion are separate concepts! -- Regards, Casey -- http://mail.python.org/mailman/listinfo/python-list

Re: New tail recursion decorator

2006-05-12 Thread Casey Hawthorne
Your examples are not tail recursive because an extra step is needed before returning from the function call and that step cannot be thrown away! Alexander Schmolck [EMAIL PROTECTED] wrote: def even(n): return n == 0 or not odd(n-1) def odd(n): return n == 1 or not even(n-1) --

Re: which is better, string concatentation or substitution?

2006-05-08 Thread Casey Hawthorne
[EMAIL PROTECTED] (Roy Smith) wrote: O(n^0), which is almost always written as O(1). This is a constant time algorithm, one which takes the same amount of steps to execute no matter how big the input is. For example, in python, you can write, x = 'foo'. That assignment statement takes the same

Re: About classes and OOP in Python

2006-04-11 Thread Casey Hawthorne
I think it's important not to wrongly confuse 'OOP' with ''data hiding' or any other aspect you may be familiar with from Java or C++. The primary concept behind OOP is not buzzwords such as abstraction, encapsulation, polymorphism, etc etc, but the fact that your program consists of objects

How Relevant is C Today? I still need it for Writing!

2006-04-09 Thread Casey Hawthorne
How Relevant is C Today? I still need it for Writing! -- Regards, Casey -- http://mail.python.org/mailman/listinfo/python-list

Re: New development windows, IronPython or PythonWin

2006-03-23 Thread Casey Hawthorne
Butternut squash [EMAIL PROTECTED] wrote: [EMAIL PROTECTED] wrote: IronPython is currently nowhere near production quality. I would not recommend it. But it's so cool. It's cool to have bugs? That really BUGS ME! -- Regards, Casey -- http://mail.python.org/mailman/listinfo/python-list

Re: May i customize basic operator (such as 1==3)?

2006-02-22 Thread Casey Hawthorne
Cannot one subclass the builtin types? I have heard, that one should always use objects when programming and avoid the builtin types! Then one is prepared to change objects at will and not rely on any special properties of the builtin types! Robert Kern [EMAIL PROTECTED] wrote: Casey

Re: May i customize basic operator (such as 1==3)?

2006-02-21 Thread Casey Hawthorne
I believe you are asking for a side effect from the == operator. Add print statements to the __eq__ method. kanchy kang [EMAIL PROTECTED] wrote: Hi,all as we know, we can override the operator of one object(for example __eq__). my question is, how to override the basic operator? for example,

Re: a question regarding call-by-reference

2006-02-08 Thread Casey Hawthorne
Don't send the whole list or parts of the list to the server unless actually needed! If the server has to do an append, have the server send back the new elements to be appended and then do the appending on the client side! Or Does the homework specify that the entire mutable type be sent to

Re: Too Many if Statements?

2006-02-07 Thread Casey Hawthorne
Try the state(s) pattern! slogging_away [EMAIL PROTECTED] wrote: Hi - I'm running Python 2.4.2 (#67, Sep 28 2005, 12:41:11) [MSC v.1310 32 bit (Intel)] on win32, and have a script that makes numerous checks on text files, (configuration files), so discrepancies can be reported. The script works

Re: Python vs Ruby

2005-10-20 Thread Casey Hawthorne
What languages do you know already? What computer science concepts do you know? What computer programming concepts do you know? Have you heard of Scheme? Ruby is a bit Perl like -- so if you like Perl, chances are you might like Ruby. Python is more like Java. I have heard, but have not

The value of Big-O notation is for scale ability and the value of the constant of proportionality!

2005-10-16 Thread Casey Hawthorne
The value of Big-O notation is for scale ability, since quite often a an algorithm used for small N is forgotten about in a large program and not changed when the program has to deal with larger inputs. It's also useful to know the constant of proportionality, for different platforms, for code

Re: Vancouver Python and Zope: Next Meeting Oct 2nd

2005-09-26 Thread Casey Hawthorne
Where is ActiveState? On Mon, 26 Sep 2005 11:58:33 -0700, you wrote: The Vancouver Python and Zope user groups next meeting is on Oct 4th, at the usual place, ActiveState at 7. Mishtu Banerjee will be giving a talked entitled Desperately Seeking Abstraction I built an SQL query generator (as

Re: Bug in string.find; was: Re: Proposed PEP: New style indexing, was Re: Bug in slice type

2005-08-24 Thread Casey Hawthorne
contained in the range [start, end) Does range(start, end) generate negative integers in Python if start = 0 and end = start? -- Regards, Casey -- http://mail.python.org/mailman/listinfo/python-list

Re: up to date books?

2005-08-22 Thread Casey Hawthorne
Would you consider releasing an ebook in the mean time? [EMAIL PROTECTED] wrote: Glad to hear that my efforts to cover some of 2.3's release features in a mostly-2.2 book were appreciated. I'm probably going to do the same thing for the 2nd edition of the Nutshell: wait until 2.5 alpha's out so

Re: Permutation Generator

2005-08-14 Thread Casey Hawthorne
It's hard to make complete permutation generators, Knuth has a whole fascicle on it - The Art of Computer Programming - Volume 4 Fascicle 2 - Generating All Tuples and Permutations - 2005 -- Regards, Casey -- http://mail.python.org/mailman/listinfo/python-list

Re: Creating Palm OS programs with python?

2005-08-10 Thread Casey Hawthorne
Apparently there is a PVM (Python Virtual Machine) for the Palm OS, but it is several versions back! Jython, might be better, but it is also a few versions back! [EMAIL PROTECTED] wrote: QUick question: Is it possible to create a palm os program to use on a PDA with python? THanks --

Is there a way to determine -- when parsing -- if a word contains a builtin name or other imported system module name?

2005-08-03 Thread Casey Hawthorne
Is there a way to determine -- when parsing -- if a word contains a builtin name or other imported system module name? Like iskeyword determines if a word is a keyword! -- Regards, Casey -- http://mail.python.org/mailman/listinfo/python-list

Re: Strange os.path.exists() behaviour

2005-07-20 Thread Casey Hawthorne
Does this work differently under other platforms? Pierre Quentel [EMAIL PROTECTED] wrote: os.path.exists(path) returns True if path exists But on Windows it also returns True for path followed by any number of dots : Python 2.4 (#60, Nov 30 2004, 11:49:19) [MSC v.1310 32 bit (Intel)] on win32

Re: IDLE in Jython

2005-07-15 Thread Casey Hawthorne
How about the following: - making Jython mostly work up to Python 2.4? - making a PVM (Python Virtual Machine) for the Palm? -- Regards, Casey -- http://mail.python.org/mailman/listinfo/python-list

Re: What is Expresiveness in a Computer Language?

2005-07-10 Thread Casey Hawthorne
It is easier to write code a computer can understand than others can understand! It is harder to read code than to write code! -- Regards, Casey -- http://mail.python.org/mailman/listinfo/python-list

Re: What are __slots__ used for?

2005-07-04 Thread Casey Hawthorne
To save a a few bytes (10?) per instance instead of having a dict to hold attributes one has slots! Designed for having lots of instances (millions?) at the same time to save space! Ric Da Force [EMAIL PROTECTED] wrote: I am a C# programmer and new to the language and I am trying to debug some

Re: Newbie: Help Figger Out My Problem

2005-06-28 Thread Casey Hawthorne
It may be shorter but it keeps the entire list in memory and has to iterate over the list twice! Does he/she need the entire list? import random heads = 0 flips = 100 for i in xrange(flips): if random.randint(0,1): heads += 1 print Heads:%s % heads print Tails:%s % (flips - heads) Devan

Re: Looking For Geodetic Python Software

2005-06-22 Thread Casey Hawthorne
Tim Daneliuk [EMAIL PROTECTED] wrote: Is anyone aware of freely available Python modules that can do any of the following tasks: 1) Given the latitude/longitude of two locations, compute the distance between them. Distance in this case would be either the straight-line flying distance,

What platforms have Python Virtual Machines and what version(s) of Python do they support?

2005-06-18 Thread Casey Hawthorne
What platforms have Python Virtual Machines and what version(s) of Python do they support? In particular: Palm OS PocketPC What version of Python does Jython support? Does any machine running a JVM support Jython? Does it depend on the JVM version and if it's J2ME? Thank you for your time! --

Re: Information about Python Codyng Projects Ideas

2005-06-01 Thread Casey Hawthorne
The slightly slower startup time makes no difference for apps running 24 hours a day, except when reloading changed source modules! I imagine reloading modules is also slower -- but I could be mis t ak en! -- Regards, Casey -- http://mail.python.org/mailman/listinfo/python-list

Is there a better way to delete the image from a Tkinter button other than the following:

2005-05-12 Thread Casey Hawthorne
Is there a better way to delete the image from a Tkinter button other than the following: - reconstructing the button - image=blank.gif -- Regards, Casey -- http://mail.python.org/mailman/listinfo/python-list

Re: python without OO

2005-01-26 Thread Casey Hawthorne
The object-oriented programming paradigm has an undeserved reputation as being complicated; most of the complexity of languages such as C++ and Java has nothing to do with their object orientation but comes instead from the type declarations and the mechanisms to work around them. This is a prime

Re: What can I do with Python ??

2005-01-02 Thread Casey Hawthorne
Aren't games using full screen mode to address only 320 by 240 resolution for faster screen painting? If one used only 320 by 240 in a window, then that would be 1/4 of the screen or less! -- Regards, Casey -- http://mail.python.org/mailman/listinfo/python-list