Re: Pycon disappointment

2008-03-16 Thread Bill Mill
, I'm just posting it because I found it thought-provoking.) -Bill Mill http://billmill.org -- http://mail.python.org/mailman/listinfo/python-list

Re: Klik2 Project, Python apps on linux

2008-01-27 Thread Bill Mill
Jason, Can you give a little more detail on the problem? What's the directory structure of a Klik package that's failing look like? What program is trying to import what module from where that's failing? -Bill Mill On Jan 27, 2008 1:49 AM, Jason Taylor [EMAIL PROTECTED] wrote: Hi We've been

Re: Compiler-AST-Walk-Visitor: Any Examples or Documentation?

2007-03-23 Thread Bill Mill
=Search+Code It seems from a superficial look that some of those files would be helpful as examples. -Bill Mill bill.mill at gmail.com http://billmill.org -- http://mail.python.org/mailman/listinfo/python-list

Re: windows blinds

2007-03-14 Thread Bill Mill
the Win32 API. As for how to use the win32 API, you could try asking on comp.os.ms- windows.programmer.win32 ( http://groups.google.com/group/comp.os.ms-windows.programmer.win32/topics?lnk=srg ), because that's some fiendish stuff. -Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman

Re: Regex Question

2007-01-18 Thread Bill Mill
Gabriel Genellina wrote: At Tuesday 16/1/2007 16:36, Bill Mill wrote: py import re py rgx = re.compile('1?') py rgx.search('a1').groups() (None,) py rgx = re.compile('(1)+') py rgx.search('a1').groups() But shouldn't the ? be greedy, and thus prefer the one match

Re: Regex Question

2007-01-16 Thread Bill Mill
James Stroud wrote: Bill Mill wrote: Hello all, I've got a test script: start python code = tests2 = [item1: alpha; item2: beta. item3 - gamma--, item1: alpha; item3 - gamma--] def test_re(regex): r = re.compile(regex, re.MULTILINE) for test in tests2

Regex Question

2007-01-10 Thread Bill Mill
: (.*?)\.)?) (None,) (None,) Shouldn't the '?' greedily grab the group match? Thanks Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

iTunes Search Algorithm/Data Structure?

2006-08-17 Thread Bill Mill
instantaneously as you type, even with very large lists with many elements per row. I'd like the employee list in my current application to be similarly filtered, but I don't quite see how. Thoughts? -Bill Mill bill.mill at gmail.com billmill.org -- http://mail.python.org/mailman/listinfo/python-list

Re: python website

2005-12-16 Thread Bill Mill
. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Default method arguments

2005-11-15 Thread Bill Mill
want to use 'A' class as following : myA = A(5) myA.f() and get printed '5' as a result.) class A: def __init__(self, n): self.data = n def f(self, x=None): if not x: x = self.data print x myA = A(5) myA.f() 5 Peace Bill Mill bill.mill

Re: Default method arguments

2005-11-15 Thread Bill Mill
much, and we see the result. It could have been a good debugging lesson for him if he'd tried to pass 0; I think I'll use that as my excuse. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Python obfuscation

2005-11-10 Thread Bill Mill
the user to contact you to use it, and that's a deal with the devil. One you might need to make if security is that important to you, as Microsoft and Valve have decided it is, but it's a deal with the devil nonetheless. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo

Re: PYTHON LOOSING FOR JAVA???????

2005-11-08 Thread Bill Mill
to know what will be the future of this wonderful language called Python?? I think I know Although, the future is difficult to predict??? +1 QOTW Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: python server

2005-11-07 Thread Bill Mill
? Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Will python never intend to support private, protected and public?

2005-09-29 Thread Bill Mill
... #special private variable! ... t._test__i += 6 t.i got i 7 But, if your users can't figure out that they shouldn't be changing the variable called t._test__i without expecting side effects, what do you think of the users of your class? Python is for consenting adults. Peace Bill Mill

Re: Will python never intend to support private, protected and public?

2005-09-29 Thread Bill Mill
Error correction time! #here's how the crazy hackers subclassing your code can break your super ... #special private variable! ... That should be using your code not subclassing your code. D'oh! Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: A Moronicity of Guido van Rossum

2005-09-29 Thread Bill Mill
But, this post of his shows [Guido's] haughtiness +1 IQOTW (Ironic Quote Of The Week. Thanks for the laughs, Xah) Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: grouping array

2005-09-29 Thread Bill Mill
) [(0,0,2,1),(0,4,2,5)] which show the top left(x1,y1) and bottom right(x2,y2) corners of each group.hope i am clear. I don't understand. Could you give some inputs with expected outputs and some explanation? Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo

Re: python's performance

2005-09-29 Thread Bill Mill
something that's answerable, and we'll try to help you.) Peace Bill Mill bill.mill at gmail.com On 9/29/05, James Hu [EMAIL PROTECTED] wrote: Hi, I used python and PIL to capture image from a digital camera, It seems like it took more than 1 second to capture a 1280x1024 image, however, the demo

Re: python's performance

2005-09-29 Thread Bill Mill
for one image with the same size. Don't know why python and PIL is so slow, any idea to improve the performance? Thanks a lot! James -- http://mail.python.org/mailman/listinfo/python-list Bill Mill bill.mill at gmail.com wrote: You've gotta framinate your capacitor to speed it up

Re: A Moronicity of Guido van Rossum

2005-09-29 Thread Bill Mill
Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: [Python-Dev] PEP 350: Codetags

2005-09-27 Thread Bill Mill
before you ask people to move their cheese. :) +1 I agree with PJE almost entirely. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: How to show percentage

2005-09-22 Thread Bill Mill
You need to convert 1 or 3 to a float. How about: def pct(num, den): return (float(num)/den) * 100 ... pct(1, 3) 33.329 Peace Bill Mill bill.mill at gmail.com On 22 Sep 2005 10:51:43 -0700, Sen-Lung Chen [EMAIL PROTECTED] wrote: Dear All: I have a question of show percentage

Re: C#3.0 and lambdas

2005-09-21 Thread Bill Mill
), (x2, y2) = p1, p2 return math.sqrt((x2 - x1)**2 + (y2 - y1)**2) But the question is - why go to the effort to remove the (by your admission) slightly nicer version? Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: C#3.0 and lambdas

2005-09-19 Thread Bill Mill
(a, (b,c)): ... foo(1, (2,3)) Agreed. I discovered them when I wondered wouldn't it be neat if functions unpacked tuples just like regular code does? And was pleasantly surprised to find that they did. +1 on keeping them. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org

Re: Speed quirk: redundant line gives six-fold speedup

2005-08-25 Thread Bill Mill
to get there. And, finally, you should forward this to the python-dev list, if somebody hasn't already. There are more people who know a ton about python internals there. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Speed quirk: redundant line gives six-fold speedup

2005-08-25 Thread Bill Mill
statements from the program, the dummy and non-dummy variable versions take indentical time. Can others reproduce this? I'm Investigating further... Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Speed quirk: redundant line gives six-fold speedup

2005-08-25 Thread Bill Mill
Bill Mill wrote: Pentium M 1.8 GHz Windows 2k. Here's the top of the profile results for fast and slow on my machine (these won't look decent except in a fixed-width font): snip profiles Interestingly, the test.py:36 line, which takes 45 seconds (!!) in the slow version, does not appear

Re: Speed quirk: redundant line gives six-fold speedup

2005-08-25 Thread Bill Mill
On 8/25/05, Jack Diederich [EMAIL PROTECTED] wrote: On Thu, Aug 25, 2005 at 01:35:04PM -0400, Bill Mill wrote: On 8/25/05, Erik Max Francis [EMAIL PROTECTED] wrote: Mark Dickinson wrote: Questions: (1) Can anyone else reproduce this behaviour, or is it just some quirk

Re: Speed quirk: redundant line gives six-fold speedup

2005-08-25 Thread Bill Mill
On 8/25/05, Erik Max Francis [EMAIL PROTECTED] wrote: Bill Mill wrote: Unlikely; 2 people have confirmed these results already. I did find, though, that if I remove all print statements from the program, the dummy and non-dummy variable versions take indentical time. Can others

Re: Speed quirk: redundant line gives six-fold speedup

2005-08-25 Thread Bill Mill
always. Often, multiple objects have a value of 1, and he's going to get one of them at random as the 'min' object. I'm pretty sure. Mark, can you confirm that this is/isn't a bug? (btw, it still runs fast with and slow without the dummies with my custom min() func) Peace Bill Mill bill.mill

Re: loop in python

2005-08-22 Thread Bill Mill
They come out even in the computer language shootout: http://shootout.alioth.debian.org/benchmark.php?test=alllang=pythonsort=fullcpu (tied 8-8 in execution time, although perl wins 4-12 on memory consumption) Peace Bill Mill On 8/23/05, km [EMAIL PROTECTED] wrote: Hi all, thing. If *all

Re: loop in python

2005-08-22 Thread Bill Mill
If you want a fast language, try Holden. I've just invented it. Unfortunately it gets the answer to every problem wrong unless the answer is 42, but boy it runs quickly. +1 QOTW (sometimes the zen master has to whack the student on the head) Peace Bill Mill bill.mill at gmail.com -- http

Re: help in algorithm

2005-08-11 Thread Bill Mill
clustering. I ask because I've done some LSI [1], and could help him out with that if he is doing it. While I'm on the subject, is there any general interest in my python LSI code? [1] http://llimllib.f2o.org/files/lsi_paper.pdf Peace Bill Mill -- http://mail.python.org/mailman/listinfo/python-list

Re: The ONLY thing that prevents me from using Python

2005-08-05 Thread Bill Mill
snip I really wish Python could be more widely available on web server machines. This is just my own experience and I would like to hear your comments. I would like a pony... no, wait, even better, a unicorn! Peace Bill Mill bill.mill at gmail.com PS (the gist is, why don't you offer some

Re: sample code for parsing html file to get contents of td fields

2005-08-04 Thread Bill Mill
tdbsomething/b else/td and\nanother thing tdin a td/td and again else In [2]: import re In [3]: r = re.compile('td(.*?)/td', re.S) In [4]: r.findall(x) Out[4]: ['bsomething/b else', 'in a td'] If not, you'll have to explain more clearly what you want. Peace Bill Mill bill.mill at gmail.com

Re: Ten Essential Development Practices

2005-07-29 Thread Bill Mill
snip although, as some argue, it's possible [GvR] thinks in base 9.5, that just doesn't seem Pythonic to me. +1 QOTW Peace Bill Mill [EMAIL PROTECTED] -- http://mail.python.org/mailman/listinfo/python-list

Re: [Beginner] Calling a function by its name in a string

2005-07-27 Thread Bill Mill
()) foobarred Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: [Beginner] Calling a function by its name in a string

2005-07-27 Thread Bill Mill
an AttributeError if func_name doesn't exist in the object; you should probably wrap it in a try/except. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: is this pythonic?

2005-07-21 Thread Bill Mill
On 7/21/05, Steven D'Aprano [EMAIL PROTECTED] wrote: On Wed, 20 Jul 2005 16:30:10 -0400, Bill Mill wrote: On 7/20/05, Simon Brunning [EMAIL PROTECTED] wrote: On 7/20/05, Mage [EMAIL PROTECTED] wrote: Or is there better way? for (i, url) in [(i,links[i]) for i in range(len(links

Re: Stupid question: Making scripts python-scripts

2005-07-21 Thread Bill Mill
functionality, you could try (assuming you use bash): /home/llimllib $ echo $@ /usr/bin/env /home/llimllib $ chmod a+x /usr/bin/env Peace Bill Mill bill.mill at gmail.com [1]: http://rootr.net/man/man/env/1 -- http://mail.python.org/mailman/listinfo/python-list

Re: Stupid question: Making scripts python-scripts

2005-07-21 Thread Bill Mill
On 7/21/05, Bill Mill [EMAIL PROTECTED] wrote: On 7/21/05, Jan Danielsson [EMAIL PROTECTED] wrote: Hello all, How do I make a python script actually a _python_ in unix:ish environments? I know about adding: #!/bin/sh ..as the first row in a shell script, but when I

Re: is this pythonic?

2005-07-20 Thread Bill Mill
On 7/20/05, Bill Mill [EMAIL PROTECTED] wrote: On 7/20/05, Simon Brunning [EMAIL PROTECTED] wrote: On 7/20/05, Mage [EMAIL PROTECTED] wrote: Or is there better way? for (i, url) in [(i,links[i]) for i in range(len(links))]: for i, url in enumerate(links): +2 for creating

Re: smtplib

2005-07-18 Thread Bill Mill
this change? check out the CVS changelog to see what's changed with it: http://cvs.sourceforge.net/viewcvs.py/python/python/dist/src/Lib/smtplib.py?rev=1.70view=log Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

odd python/linux/cherrypy behavior

2005-07-16 Thread Bill Mill
that if I move it to my ext3 drive, it again works perfectly. Prints out the same information, says it's waiting on 8080, but this time, I can access it. Can anybody posit a guess as to why it would behave this way? Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo

Re: odd python/linux/cherrypy behavior

2005-07-16 Thread Bill Mill
On 7/16/05, Neil Hodgson [EMAIL PROTECTED] wrote: Bill Mill: ... a FAT partition for data as a dmz which both linux and NT can access ... Yesterday, I downloaded the new release of cherrypy, and stuck it on the dmz drive. ... Eventually, after thinking it's a hosts file problem

Re: odd python/linux/cherrypy behavior

2005-07-16 Thread Bill Mill
On 7/16/05, Dennis Lee Bieber [EMAIL PROTECTED] wrote: On Sat, 16 Jul 2005 19:54:31 -0400, Bill Mill [EMAIL PROTECTED] declaimed the following in comp.lang.python: The FAT dirs are mounted with the following options: defaults,user,umask=000 . I'm not sure what you mean by the execute

Re: Python Programming Contest

2005-07-15 Thread Bill Mill
) be used to perform the actual testing? How many tests will be run on each program? What is the penalty for a wrong answer? Peace Bill Mill PS - check out http://www.sleepinginairports.net/ before you say you can't sleep in the airport :) -- http://mail.python.org/mailman/listinfo/python-list

Re: String Manipulation

2005-07-13 Thread Bill Mill
together to do what you want to do. If you can't, feel free to ask more questions. Also, just so you know, there is a list at tutor@python.org set up just to answer questions like these. Peace Bill Mill [EMAIL PROTECTED] -- http://mail.python.org/mailman/listinfo/python-list

Re: question on input

2005-07-12 Thread Bill Mill
at http://docs.python.org/lib/built-in-funcs.html for more details. snip Peace Bill Mill -- http://mail.python.org/mailman/listinfo/python-list

Re: Yet Another Python Web Programming Question

2005-07-11 Thread Bill Mill
, but it causes a lot of errors for windows folks. I'm a frequent linux/windows switcher, and it's caused me no end of troubles - if you're getting premature end of script headers in your apache error logs, this may be your problem. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman

Re: Folding in vim

2005-07-06 Thread Bill Mill
one level, and zM closes them all recursively. It's pretty sweet. Maybe we should have a big Vim-python tip-a-thon thread? Peace Bill Mill [EMAIL PROTECTED] -- http://mail.python.org/mailman/listinfo/python-list

Re: Scipy - Latex Annotations in plots

2005-07-06 Thread Bill Mill
for you? It is a thin wrapper around Gnuplot, which is very good at producing ps format images, and is capable of producing 3 dimensional graphs. Peace Bill Mill bill.mill at gmail.com PS please try to not top-post, you can lose the rest of the thread easily -- http://mail.python.org/mailman/listinfo

Re: What is different with Python ? (OT I guess)

2005-06-14 Thread Bill Mill
like to see them publish reports much more like biologists than like mathematicians. In this way, I think that the scientific computer scientists could begin to become more like real scientists than like engineers. Just my 2 cents. Peace Bill Mill [1] http://javelina.cet.middlebury.edu/lsa/out

Re: \r\n or \n notepad editor end line ???

2005-06-08 Thread Bill Mill
\r\n3' f = file('d:/deleteme.txt', 'r') f.read() 'testing\n1\n2\n3' Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: computer algebra packages

2005-06-08 Thread Bill Mill
to be non-proprietary, or something different, but does it work? I don't have Mathematica, so I don't know. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Convert from numbers to letters

2005-05-20 Thread Bill Mill
was pleasantly surprised that it did. Peace Bill Mill bill.mill at gmail.com [1] http://tinyurl.com/89zar I think there was another about ways to improve tuple unpacking, but I didn't find it in a brief search. This is with PythonWin 2.4 (#60, Feb 9 2005, 19:03:27) [MSC v.1310 32 bit (Intel

Re: Convert from numbers to letters

2005-05-19 Thread Bill Mill
On 19 May 2005 06:56:45 -0700, rh0dium [EMAIL PROTECTED] wrote: Hi All, While I know there is a zillion ways to do this.. What is the most efficient ( in terms of lines of code ) do simply do this. a=1, b=2, c=3 ... z=26 Now if we really want some bonus points.. a=1, b=2, c=3 ...

Re: Convert from numbers to letters

2005-05-19 Thread Bill Mill
in enumerate(sorted([''.join((x, y)) for x in alpha for y in [''] + [z for z in alpha]], key=len)): globals()[digraph]=i+1 How do you implement this sucker?? Works just fine for me. Let me know what error you're getting and I'll help you figure it out. Peace Bill Mill bill.mill at gmail.com

Re: Convert from numbers to letters

2005-05-19 Thread Bill Mill
to remember that there are not, but I could be wrong. Hope this helps. Peace Bill Mill [EMAIL PROTECTED] -- http://mail.python.org/mailman/listinfo/python-list

Re: Convert from numbers to letters

2005-05-19 Thread Bill Mill
() return l2 And from your other email: I need to go the other way! tuple2coord Sorry, I only go one way. It should be transparent how to do it backwards. Peace Bill Mill [EMAIL PROTECTED] -- http://mail.python.org/mailman/listinfo/python-list

Re: Convert from numbers to letters

2005-05-19 Thread Bill Mill
On 5/19/05, Peter Otten [EMAIL PROTECTED] wrote: Bill Mill wrote: Traceback (most recent call last): Filestdin,line1,in? NameError: name 'sorted' is not defined I think you're probably using 2.4 ?? Yes, sorted() is new in python 2.4 .You could use a very lightly tested pure

Re: Python Documentation (should be better?)

2005-05-12 Thread Bill Mill
(builtin), etc. in the appropriate alphabetical positions. +1 TJR +1 Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: How return no return ?

2005-05-12 Thread Bill Mill
be syntactically invalid. Could you perhaps repeat your question with an example of what behavior is surprising you? Peace Bill Mill bill.mill at gmail.com Fredrik Lundh [EMAIL PROTECTED] escribió en el mensaje news:[EMAIL PROTECTED] Ximo wrote: I am doing a interpret of lines

Re: increment bits

2005-05-12 Thread Bill Mill
', '0xf6', '0xf7', '0xf8', '0xf9', '0xfa', '0xfb', '0xfc', '0xfd', '0xfe', '0xff'] Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Python Graphing Utilities.

2005-05-11 Thread Bill Mill
chosen. If you want additional fonts, set the AFMPATH environment variable to point to the dir containing your AFM font files. matplotlib willl recursively search any directory in AFMPATH, so you only need to specify a base directory if multiple subdirectories contaning '*.afm' files. Peace Bill

Re: Python Graphing Utilities.

2005-05-11 Thread Bill Mill
On 5/11/05, Torsten Bronger [EMAIL PROTECTED] wrote: Hallöchen! Bill Mill [EMAIL PROTECTED] writes: On 5/11/05, Torsten Bronger [EMAIL PROTECTED] wrote: Fernando Perez [EMAIL PROTECTED] writes: [...] [...] Matplotlib is very good, has an active development community

Re: Python Graphing Utilities.

2005-05-10 Thread Bill Mill
and windows. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

replace string patern with different value

2005-05-09 Thread Bill Mill
yeah And, if I may, I recommend the Python Tutorial at http://docs.python.org/tut/tut.html . Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Listing of declared variables and functions

2005-05-09 Thread Bill Mill
/re.pyc', 'x': 12, '__name__': '__main__', 'z': 13, '__doc__': N one} Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: hard memory limits

2005-05-06 Thread Bill Mill
RAM or swap won't help at all. Raising the per-process limits is the solution. A quick google shows it to be mac os X, and a pretty frequent error message. http://www.google.com/search?hl=enq=%22vm_allocate%20(size%20%3D%22btnG=Google+Search Peace Bill Mill bill.mill at gmail.com

Re: Getting number of iteration

2005-05-06 Thread Bill Mill
in lst: print iteration %d on element %s % (n, x) n += 1 And you shouldn't use list as a variable name; list() is a built-in function which you'll clobber if you do. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Getting number of iteration

2005-05-06 Thread Bill Mill
On 5/6/05, Bill Mill [EMAIL PROTECTED] wrote: On 5/6/05, Florian Lindner [EMAIL PROTECTED] wrote: Hello, when I'm iterating through a list with: for x in list: how can I get the number of the current iteration? Python 2.4 and greater: ummm, make that 2.3 and greater. I always

Re: dictionary comparison

2005-05-05 Thread Bill Mill
': sun = parse_patch_file(open('sun-patchlist')) serverx = parse_patch_file(open('serverx-patchlist')) diff_patches(sun, serverx) diff_revs(sun, serverx) Hope this helps. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Which IDE is recommended?

2005-04-27 Thread Bill Mill
/thread/2225676eb7e1b4e/cdee764dfa2b5391?q=best+IDernum=1#cdee764dfa2b5391 Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: What is situation with threads in Python

2005-04-25 Thread Bill Mill
On 4/25/05, Leonard J. Reder [EMAIL PROTECTED] wrote: Hello Mark, I took your three day course here at JPL and recall that you said something was wrong with the implementation of threads within Python but I cannot recall what. So what is wrong with threads in Python? I'm going to guess

Re: What's do list comprehensions do that generator expressions don't?

2005-04-25 Thread Bill Mill
should be relatively simple), it's not worth breaking that Jeremy code. Well, the code that relies on the dangling variable deserves to break. Agreed. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Do I need a nested lambda to do this?

2005-04-25 Thread Bill Mill
, 3), (4.23420004, 1))] Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list -- http://mail.python.org/mailman/listinfo/python-list

Re: a=[ lambda t: t**n for n in range(4) ]

2005-04-23 Thread Bill Mill
that was kinda neat. If you wanted to obfuscate some python, this would be an awesome trick - hide the value of t somewhere early in the function then pull a variation of this out later. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Why Python does *SLICING* the way it does??

2005-04-20 Thread Bill Mill
, and it's an unmitigated disaster. It adds needless complexity. What our slicing system loses in elegance in a few cases, it more than makes up for in consistency throughout all programs. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Why Python does *SLICING* the way it does??

2005-04-20 Thread Bill Mill
On 20 Apr 2005 13:39:42 GMT, Antoon Pardon [EMAIL PROTECTED] wrote: Op 2005-04-20, Bill Mill schreef [EMAIL PROTECTED]: On 20 Apr 2005 12:52:19 GMT, Antoon Pardon [EMAIL PROTECTED] wrote: Op 2005-04-20, Torsten Bronger schreef [EMAIL PROTECTED]: Hallöchen! [EMAIL PROTECTED] (Nick

Re: Troll? was: Re: goto statement

2005-04-20 Thread Bill Mill
product, to try and avoid decompilation, which is often a desirable function for commercial entities. (Not that I have the technical knowledge to agree or disagree with what he said, I'm just trying to help clear up what's become a fairly bogged-down argument.) Peace Bill Mill bill.mill at gmail.com

Re: New Python regex Doc (was: Python documentation moronicities)

2005-04-19 Thread Bill Mill
make an effort at improving the docs before submitting them. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Strings and Lists

2005-04-18 Thread Bill Mill
. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: A little request about spam

2005-04-15 Thread Bill Mill
! Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Compute pi to base 12 using Python?

2005-04-14 Thread Bill Mill
recommend running it from a cmd window (which worked fine). Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: A little request about spam

2005-04-14 Thread Bill Mill
On 4/14/05, César Leonardo Blum Silveira [EMAIL PROTECTED] wrote: Yeah that is happening to me too! Almost all my python-list e-mails go to the Spam box. Maybe we should contact the gmail admins? I've already contacted the gmail admins. There was no response. Peace Bill Mill bill.mill

Re: A little request about spam

2005-04-14 Thread Bill Mill
On 4/14/05, Fredrik Lundh [EMAIL PROTECTED] wrote: Bill Mill wrote: Maybe we should contact the gmail admins? I've already contacted the gmail admins. There was no response. have you tried reading the newsgroup via http://groups-beta.google.com/group/comp.lang.python while

Re: preallocate list

2005-04-13 Thread Bill Mill
= timeit.Timer('test2()', 'from __main__ import test2') print time1: %f % t1.timeit(100) print time2: %f % t2.timeit(100) 09:09 AM ~$ python test.py time1: 12.435000 time2: 12.385000 Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: preallocate list

2005-04-13 Thread Bill Mill
test.py time1: 3.352000 time2: 3.672000 The preallocated list is slightly faster in most of my tests, but I still don't think it'll bring a large performance benefit with it unless you're making a truly huge list. I need to wake up before pressing send. Peace Bill Mill -- http://mail.python.org

Re: Codig style: or

2005-04-13 Thread Bill Mill
to pep 257, which is all about docstrings: http://www.python.org/peps/pep-0257.html Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: some sort of permutations...

2005-04-12 Thread Bill Mill
-recursive algorithm to do the same thing? And, while I'm asking that question, is there a good reference for finding such algorithms? Do most people keep an algorithms book handy? Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Lambda: the Ultimate Design Flaw

2005-04-07 Thread Bill Mill
On Apr 7, 2005 1:15 AM, Greg Ewing [EMAIL PROTECTED] wrote: Scott David Daniels wrote: Aahz wrote: You just can't have your cake and eat it, too. I've always wondered about this turn of phrase. I seldom eat a cake at one sitting. You need to recursively subdivide the cake until

Re: sorting a list and counting interchanges

2005-04-07 Thread Bill Mill
graduated last May) While I'm at it though, I want to thank Tim for that post. It was one of those posts where afterwards you say of course! but beforehand I was totally thinking of it the wrong way. Brought me right back to Abstract. Peace Bill Mill bill.mill at gmail.com In Python when you have

Re: sorting a list and counting interchanges

2005-04-07 Thread Bill Mill
not in seen just to really frustrate the guy reading your code. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: shebang in cross platform scripts

2005-04-06 Thread Bill Mill
What the others have said already is true, that it will be ignored on windows, with one caveat. The shebang is interpreted by Apache if your script is a CGI script. So, if your script is a CGI, you will need to have a windows version and a nix version. Peace Bill Mill bill.mill at gmail.com

Re: shebang in cross platform scripts

2005-04-06 Thread Bill Mill
install a link in /usr/bin to whereever python lives, and expect #!/usr/bin/python to work just fine. This works in cygwin as well; I didn't mention cygwin since the OP seemed to be asking about windows distribution, but it's a good point. Peace Bill Mill -- http://mail.python.org/mailman

Re: change extensions

2005-04-05 Thread Bill Mill
should really use in_file.splitext - your script renames myfile.with.lots.of.dots.txt to myfile.text instead of myfile.with.lots.of.dots.text . If you *really* wanted to use split(), it oughta be ''.join(in_file.split('.')[:-1]) , but why not use the built-in? Peace Bill Mill bill.mill at gmail.com

Re: How to reload local namespace definitions in the python interpreter?

2005-04-04 Thread Bill Mill
Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

Re: Pseudocode in the wikipedia

2005-04-01 Thread Bill Mill
since you often write many of them in a row, whereas you almost always make one assignment per line. I use := every day in PL/SQL, and it's one of the few positive syntactical features of the language. Peace Bill Mill bill.mill at gmail.com -- http://mail.python.org/mailman/listinfo/python-list

  1   2   >