Rajesh Sathyamoorthy wrote:
> I tried the script and had to get a hexdigest to get the value provided
>
> My test:
> SimplyMEPIS-3.3.1-1.iso
> checksum: 41a19060d3bb37bd596708ba77964491
> i got: 41a19060d3bb37bd596708ba77964491
>
> Do people normally provide md5 checksum in a *hexadecimal string?
>>The values of some inputs are encoded using html entities.
>>How can I decode a string like "Bessy's cat" in "Bessy's cat"?
>>
>>
>
>this snippet might help:
>
>http://effbot.org/zone/re-sub.htm#strip-html
>
>
Thank you, worked like a charm. :-)
Laszlo
--
http://mail.python.org/m
Hi, Anybody, please help me to set PYTHONPATH to import my modules?. Where is sy.path set?In some python groups site, to import the user modules, they explained to create one __init__.py file in my module directory (this file should include __all__ variable, which refer to the modules
Is there a way using any of the Python UI toolkits to generate popup
menus outside the context of an application? For example,
middle-clicking on the desktop shows a list of shortcuts to choose
from.
Pointers to source examples would be appreciated.
--
Cheers,
Rich.
--
http://mail.python.org/m
Rares Vernica wrote:
> Isn't the following code supposed to return ('1994')?
>
> >>> re.search('(\d{4})?', '4 1994').groups()
> (None,)
it's supposed to return the first thing that matches your pattern, which,
in this case, is the empty string at the beginning of the target string.
if you want
Rares Vernica wrote:
> Hi,
>
> Isn't the following code supposed to return ('1994')?
>
> >>> re.search('(\d{4})?', '4 1994').groups()
> (None,)
>
> Thanks,
> Ray
The ? is allowing it to not match before it finds the 1994.
Note:
py> re.search('(\d{4})?', '1994 4').groups()
('1994',)
James
-
Hi,
Isn't the following code supposed to return ('1994')?
>>> re.search('(\d{4})?', '4 1994').groups()
(None,)
Thanks,
Ray
--
http://mail.python.org/mailman/listinfo/python-list
hi
am using Tix notebook and i have two frames in that. am adding some
widgets in to both of the frames. now i want to delete all of the
widgets in one of the frame. i dont want to delete the frame, but its
childres.
so how can i get the sub widgets within that frame.
Thanks in advance
Anil
--
1) indentation:
I claim that this is a trivial matter. Indentation is enforced, but if
you want to end all your blocks with #end, feel free.
Or write a preprocessor to go from your preferred block style to
python's
2) self.something tedious to look at.
Again, you can somewhat work around this i
>Alas, somebody will now quote Emerson at you, I fear;-).
Let them come :-)
I almost always see this (mis)quoted as:
"consistency is the hobgoblin of little minds"
which is not really what Emerson said. The full quote is:
"A foolish consistency is the hobgoblin of little minds"
I would say t
Okay, now I get the correct number of 561 pseudoprimes, 5, so I can
assume that it is indeed working right. Whew. Thanks for the help on
that one. Now, I only wish I could change the answer to my last
homework assignment... Oh well.
--
http://mail.python.org/mailman/listinfo/python-list
Ahh, I see, I missed doing the last step in my M-R test. Hmmm. Well,
got that one fixed now, time for a new release I guess. Sigh. I do seem
to be going through them rather quickly...
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] wrote:
> Hi,
>
> thanks for the reply. I was not aware of this in raw strings (and
> frankly, don't like it... but who cares about that :-) )
>
Healthy attitude!
> When I needed embedded quotes in a raw string I went the triple quote
> route:
>
> a = r'''check \' this'''
>
>
Frank Millman wrote:
[...]
> There is a server component and a client component. All the business
> logic is performed on the server.
Oh, what a give-away. If the logic is in the server, then the
client component should probably be the user's chosen web browser.
> The client communicates with
sturlamolden wrote:
> Robert Kern wrote:
>
>
>>And you need to ask why Python is a better Matlab than Matlab?
>
>
>
> First there are a few things I don't like:
>
> 1. Intendation as a part of the syntax, really annoying.
>
Troll. You think this is going away because *you* don't like it? Am
Paul Boddie wrote:
> Yes, Python does this - it puts the directory of bar.py (B in this
> case) in sys.path, but not the directory in which you're sitting when
> you run the program from the shell (A in this case).
This seems to be OS dependent. If I put 'print sys.path' at the start of
site.py (
Paul Boddie wrote:
> fortepianissimo wrote:
> > Hm this doesn't work. Say I have the following directory structure:
> >
> > A
> > |--- util
> > ||--- foo.py
> > |
> > |--- B
> > |--- bar.py
> >
> >
> > And bar.py has this line
> >
> > from util import foo
>
> This would only work with A in
Tuvas wrote:
[...]
> Actually, I did another test, and realized that it was indeed a bug in
> the code. Yikes. Oh well, thanks for the help in identifying it!
>
> An example that would be alot easier is this:
>
Mod(16,561).is_strong_pseudo_prime()
>
> True
Hmmm...my M-R tester disagrees...
> hi;
> say i have a text file with a string ( say '(XYZ)') and I want to find
> the number of line where this string has occured. What is the best way
> to do that?
I would suggest:
# Read file contents
lines = file('filename.txt').readlines()
# Extract first line number containing 'XYZ' string
M.N.A.Smadi wrote:
> hi;
> say i have a text file with a string ( say '(XYZ)') and I want to find
> the number of line where this string has occured. What is the best way
> to do that?
>
> what about if that string was say a 0 with leading and trailing white
> spaces, would that be any differen
M.N.A.Smadi wrote:
> hi;
> say i have a text file with a string ( say '(XYZ)') and I want to find
> the number of line where this string has occured. What is the best way
> to do that?
>
> what about if that string was say a 0 with leading and trailing white
> spaces, would that be any differen
Interesting - Python seems to act differently under Windows then. Here
I'm using Python 2.4 on Mac OS X. With all of the files, directories
and command exactly like yours, it's still not working.
One thing I noticed is that you have this 'C:\\WUTemp\\A' when you
print sys.path in B/bar.py, but min
hi;
say i have a text file with a string ( say '(XYZ)') and I want to find
the number of line where this string has occured. What is the best way
to do that?
what about if that string was say a 0 with leading and trailing white
spaces, would that be any different?
thanks
moe smadi
--
http://m
Xavier Morel <[EMAIL PROTECTED]> wrote:
> Francois wrote:
> > 1) In Ruby there is a risk of "Variable/Method Ambiguity" when calling
> > a method with no parameters without using () :
> >
> Yes, but that's in my opinion a programmer error, not necessarily a
> language error.
In Python, you can
Robert Kern <[EMAIL PROTECTED]> wrote:
...
> > just a toy. And as Matlab's run-time does reference counting insted of
> > proper garbage collection, any datastructure more complex than arrays
> > are sure to leak memory (I believe Python also suffered from this as
> > some point).
>
> Python st
Sandra-24 wrote:
> I was reading over some python code recently, and I saw something like
> this:
>
> contents = open(file).read()
>
> And of course you can also do:
>
> open(file, "w").write(obj)
>
> Why do they no close the files? Is this sloppy programming or is the
> file automatically clos
fortepianissimo wrote:
> Hm this doesn't work. Say I have the following directory structure:
>
> A
> |--- util
> ||--- foo.py
> |
> |--- B
> |--- bar.py
>
>
> And bar.py has this line
>
> from util import foo
This would only work with A in sys.path/PYTHONPATH. However...
> I then run
>
>
On 3/5/06, Bill Maxwell <[EMAIL PROTECTED]> wrote:
> Thanks for the info. Knowing that, I was able to create a simple app in
> the Dabo Designer that contains a Notebook.
>
> But, I'm having a heck of a time finding any documentation at all on
> Dabo. I looked all thru the website(s), and have c
"Schüle Daniel" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
>> block (Python forbids the rebinding of variables coming from an
>> enclosing but non-global scope, to avoid facing this issue).
>
> I am not sure what you mean here
> can you elaborate on this please
>
> >>> def a():
>
I'll just play the devil's advocate here
Francois wrote:
> 1) In Ruby there is a risk of "Variable/Method Ambiguity" when calling
> a method with no parameters without using () :
>
Yes, but that's in my opinion a programmer error, not necessarily a
language error.
> 2) Ruby does not have true f
Erik Max Francis wrote:
> Robert Kern wrote:
>
>>>I usually use:
>>>
>>>try:
>>> f = open(file)
>>> contents = f.read()
>>>finally:
>>> f.close()
>>>
>>>But now I am wondering if that is the same thing. Which method would
>>>you rather use? Why?
>>
>>Just keep doing what you are doing, please.
Robert Kern wrote:
>> I usually use:
>>
>> try:
>> f = open(file)
>> contents = f.read()
>> finally:
>> f.close()
>>
>> But now I am wondering if that is the same thing. Which method would
>> you rather use? Why?
>
> Just keep doing what you are doing, please.
Note quite. The assignment
fortepianissimo wrote:
> Hm this doesn't work. Say I have the following directory structure:
> A
> |--- util
> ||--- foo.py
> |
> |--- B
> |--- bar.py
>
> And bar.py has this line
>
> from util import foo
>
> I then run
>
> python B/bar.py
>
> in directory A. Still got er
[EMAIL PROTECTED] a écrit :
> First of all, please don't flame me immediately.
Granted - we'll do it later then !-)
> I did browse archives
> and didn't see any solution to my problem.
>
> Assume I want to add a method to an object at runtime. Yes, to an
> object, not a class - because changing
> First there are a few things I don't like:
Hi, I will respond to things that others haven't responded yet
> 2. How good is matplotlib/pylab? I tried to install it but only get
> error messages so I haven't tested it. But plotting capabilities is
> really major issue.
I don't know because I hav
Rob Cowie wrote:
> I'm having a bit of trouble with this so any help would be gratefully
> recieved...
>
> After splitting up a url I have a string of the form
> 'tag1+tag2+tag3-tag4', or '-tag1-tag2' etc. The first tag will only be
> preceeded by an operator if it is a '-', if it is preceded by n
Good idea about the max and min values. Yes, urandom is os.urandom.
s2num('blah') will convert the phrase blah to ascii, and treat them as
if they were a big function.
Anyone else whose still interested, I found another small bug, but it
was in the modular (Again). It won't do much, but...
I did
Dennis Lee Bieber wrote:
> > 1. Can python do "pass by reference"? Are datastructures represented by
> > references as in Java (I don't know yet).
> >
> Everything in Python is a reference to an object. I think the
> question you want is more on the lines of: Can I change an object that
> ha
Hm this doesn't work. Say I have the following directory structure:
A
|--- util
||--- foo.py
|
|--- B
|--- bar.py
And bar.py has this line
from util import foo
I then run
python B/bar.py
in directory A. Still got error
ImportError: No module named util
A check of sys.path in bar
Sandra-24 a écrit :
> I was reading over some python code recently, and I saw something like
> this:
>
> contents = open(file).read()
>
> And of course you can also do:
>
> open(file, "w").write(obj)
>
> Why do they no close the files? Is this sloppy programming or is the
> file automatically c
On Sat, 4 Mar 2006 13:08:35 -0500, "Peter Decker" <[EMAIL PROTECTED]>
wrote:
>On 3/4/06, Bill Maxwell <[EMAIL PROTECTED]> wrote:
>
>> Dabo does look really nice, but seems like it has a ways to go yet.
>>
>> I downloaded it a couple of weeks ago, and the very first thing I wanted
>> to do doesn't
On Mar 5, 2006, at 1:01 AM, sam wrote:David Treadwell wrote: exp(x) is implemented by:1. reducing x into the range |r| <= 0.5 * ln(2), such that x = k *ln(2) + r2. approximating exp(r) with a fifth-order polynomial,3. re-scaling by multiplying by 2^k: exp(x) = 2^k * exp(r)sinh(x) is mathematica
Marcin Mielżyński wrote:
> Sandra-24 wrote:
>> I was reading over some python code recently, and I saw something like
>> this:
>>
>> contents = open(file).read()
>>
>> And of course you can also do:
>>
>> open(file, "w").write(obj)
>>
>> Why do they no close the files? Is this sloppy programming or
On Mar 5, 2006, at 2:30 PM, Marek wrote:
> Assume I want to add a method to an object at runtime. Yes, to an
> object, not a class - because changing a class would have global
> effects and I want to alter a particular object only. The following
> approach fails:
>
> class kla:
> x = 1
>
> de
Sandra-24 wrote:
> I was reading over some python code recently, and I saw something like
> this:
>
> contents = open(file).read()
>
> And of course you can also do:
>
> open(file, "w").write(obj)
>
> Why do they no close the files? Is this sloppy programming or is the
> file automatically clos
Sandra-24 wrote:
> I was reading over some python code recently, and I saw something like
> this:
>
> contents = open(file).read()
>
> And of course you can also do:
>
> open(file, "w").write(obj)
>
> Why do they no close the files? Is this sloppy programming or is the
> file automatically clos
I was reading over some python code recently, and I saw something like
this:
contents = open(file).read()
And of course you can also do:
open(file, "w").write(obj)
Why do they no close the files? Is this sloppy programming or is the
file automatically closed when the reference is destroyed (aft
Francois wrote:
> I discovered Python a few months ago and soon decided to invest time in
> learning it well. While surfing the net for Python, I also saw the hype
> over Ruby and tried to find out more about it, before I definitely
> embarked on studying and practicing Python. I recently found two
Gerard Flanagan a écrit :
> Alex Martelli wrote:
>
>>Gerard Flanagan <[EMAIL PROTECTED]> wrote:
>>...
>>
>>>a = [ '+', 'tag1', '+', 'tag2', '-', 'tag3', '+', 'tag4' ]
>>>
>>>import itertools
>>>
>>>b = list(itertools.islice(a,0,8,2))
>>>c = list(itertools.islice(a,1,8,2))
>>
>>Much as I love i
[EMAIL PROTECTED] wrote:
> First of all, please don't flame me immediately. I did browse archives
> and didn't see any solution to my problem.
>
> Assume I want to add a method to an object at runtime. Yes, to an
> object, not a class - because changing a class would have global
> effects and I wa
First of all, please don't flame me immediately. I did browse archives
and didn't see any solution to my problem.
Assume I want to add a method to an object at runtime. Yes, to an
object, not a class - because changing a class would have global
effects and I want to alter a particular object only.
"Rob Cowie" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> I'm having a bit of trouble with this so any help would be gratefully
> recieved...
>
> After splitting up a url I have a string of the form
> 'tag1+tag2+tag3-tag4', or '-tag1-tag2' etc. The first tag will only be
> preceeded
Hi Alex
[...]
> The trick about distinguishing a name's exact nature based on whether
> the compiler sees an assignment to that name in some part of code is
> found in both languages, albeit in different ways. In Ruby, as you've
> pointed out, it's the heuristic used to disambiguate local variabl
Alex Martelli wrote:
> Gerard Flanagan <[EMAIL PROTECTED]> wrote:
> ...
> > a = [ '+', 'tag1', '+', 'tag2', '-', 'tag3', '+', 'tag4' ]
> >
> > import itertools
> >
> > b = list(itertools.islice(a,0,8,2))
> > c = list(itertools.islice(a,1,8,2))
>
> Much as I love itertools, this specific task wo
James Stroud wrote:
> Gerard Flanagan wrote:
> > Rob Cowie wrote:
> >
> >>I'm having a bit of trouble with this so any help would be gratefully
> >>recieved...
> >>
> >>After splitting up a url I have a string of the form
> >>'tag1+tag2+tag3-tag4', or '-tag1-tag2' etc. The first tag will only be
>
> def cran_rand(min,max):
You're shadowing built-ins here. Not a problem, but something I'd generally
avoid.
>if(min>max):
>x=max
>max=min
>min=x
If the args were a,b you could say:
maxarg,minarg = min(a,b),max(a,b)
>range=round(log(max-min)/log(256))
more
"vbgunz" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Hello all,
>
> I am just learning Python and have come across something I feel might
> be a bug.
I feel it is more likely that there in a bug in the communication process
from the manual to you, on an admittedly somewhat con
[EMAIL PROTECTED] a écrit :
> Hi,
>
> I read the mod_python documentation on the Django site but I'm getting
> this error:
>
> EnvironmentError: Could not import DJANGO_SETTINGS_MODULE
> 'accesshiphop.settings' (is it on sys.path?): No module named
> accesshiphop.settings
>
> Here's my httpd.con
Gerard Flanagan <[EMAIL PROTECTED]> wrote:
...
> a = [ '+', 'tag1', '+', 'tag2', '-', 'tag3', '+', 'tag4' ]
>
> import itertools
>
> b = list(itertools.islice(a,0,8,2))
> c = list(itertools.islice(a,1,8,2))
Much as I love itertools, this specific task would be best expressed ad
b = a[::2]
c
sturlamolden wrote:
> First there are a few things I don't like:
>
> 1. Intendation as a part of the syntax, really annoying.
Each to his own. I find having the compiler enforce indentation rules is a
real benefit. There's nothing quite so annoying as having 'coding
standards' you are supposed
Bruno Desthuilliers wrote:
> Rob Cowie a écrit :
>
>> I'm having a bit of trouble with this so any help would be gratefully
>> recieved...
>>
>> After splitting up a url I have a string of the form
>> 'tag1+tag2+tag3-tag4', or '-tag1-tag2' etc. The first tag will only be
>> preceeded by an operato
Rob Cowie a écrit :
> I'm having a bit of trouble with this so any help would be gratefully
> recieved...
>
> After splitting up a url I have a string of the form
> 'tag1+tag2+tag3-tag4', or '-tag1-tag2' etc. The first tag will only be
> preceeded by an operator if it is a '-', if it is preceded b
Gerard Flanagan wrote:
> Rob Cowie wrote:
>
>>I'm having a bit of trouble with this so any help would be gratefully
>>recieved...
>>
>>After splitting up a url I have a string of the form
>>'tag1+tag2+tag3-tag4', or '-tag1-tag2' etc. The first tag will only be
>>preceeded by an operator if it is a
Rob Cowie wrote:
> I'm having a bit of trouble with this so any help would be gratefully
> recieved...
>
> After splitting up a url I have a string of the form
> 'tag1+tag2+tag3-tag4', or '-tag1-tag2' etc. The first tag will only be
> preceeded by an operator if it is a '-', if it is preceded by n
Robert Kern wrote:
> And you need to ask why Python is a better Matlab than Matlab?
First there are a few things I don't like:
1. Intendation as a part of the syntax, really annoying.
2. The "self.something" syntax is really tedious (look to ruby)!
4. Multithreading and parallel execution is
Gerard Flanagan wrote:
> Rob Cowie wrote:
> > I'm having a bit of trouble with this so any help would be gratefully
> > recieved...
> >
> > After splitting up a url I have a string of the form
> > 'tag1+tag2+tag3-tag4', or '-tag1-tag2' etc. The first tag will only be
> > preceeded by an operator i
Rob Cowie wrote:
> I wish to derive two lists - each containing either tags to be
> included, or tags to be excluded. My idea was to take an element,
> examine what element precedes it and accordingly, insert it into the
> relevant list. However, I have not been successful.
>
> Is there a better wa
Rob Cowie wrote:
> I'm having a bit of trouble with this so any help would be gratefully
> recieved...
>
> After splitting up a url I have a string of the form
> 'tag1+tag2+tag3-tag4', or '-tag1-tag2' etc. The first tag will only be
> preceeded by an operator if it is a '-', if it is preceded by n
your suggestions worked. thanks.
--
http://mail.python.org/mailman/listinfo/python-list
sturlamolden wrote:
> Robert Kern wrote:
>>Yes, and this is why you will keep saying, "My simulation is running too
>>slowly," and "My simulation is running out of memory." All the vectorization
>>you
>>do won't make a quadratic algorithm run in O(n log(n)) time. Knowing the right
>>algorithm and
I'm having a bit of trouble with this so any help would be gratefully
recieved...
After splitting up a url I have a string of the form
'tag1+tag2+tag3-tag4', or '-tag1-tag2' etc. The first tag will only be
preceeded by an operator if it is a '-', if it is preceded by nothing,
'+' is to be assumed.
Brian Blais wrote:
> Robert Kern wrote:
>
>>That said, we have an excellent array object far superior to Matlab's.
>>
>> http://numeric.scipy.org/
>
> I'd like to ask, being new to python, in which ways is this array object far
> superior
> to Matlab's? (I'm not being sarcastic, I really would
OK, thanks!
--
http://mail.python.org/mailman/listinfo/python-list
Sandro Dentella <[EMAIL PROTECTED]> wrote:
> I need to build-up an arg list to pass to a function.
>
> Suppose I have a dictionary:
>
> opts = { 'user' : 'jack', 'addr' : 'Green Str.'}
>
> and I want to build a cmd line like this:
>
> select( user='jack', addr='Green Str.' )
select(**opt
sturlamolden <[EMAIL PROTECTED]> wrote:
> just a toy. And as Matlab's run-time does reference counting insted of
> proper garbage collection, any datastructure more complex than arrays
> are sure to leak memory (I believe Python also suffered from this as
> some point).
Yes, that was fixed in the
I need to build-up an arg list to pass to a function.
Suppose I have a dictionary:
opts = { 'user' : 'jack', 'addr' : 'Green Str.'}
and I want to build a cmd line like this:
select( user='jack', addr='Green Str.' )
I'm clueless...
TIA
sandro
*:-)
--
Sandro Dentella *:-)
http://www.t
"orangeDinosaur" <[EMAIL PROTECTED]> writes:
> Here's a section of code:
>
> for x in occupants:
> if x not in uniqueUsers and not in staff:
> uniqueUsers.append(x)
> elif x in staff and not in uniqueStaff:
> uniqueStaff.append(x)
>
> When I try to im
orangeDinosaur wrote:
> Here's a section of code:
>
> for x in occupants:
> if x not in uniqueUsers and not in staff:
> uniqueUsers.append(x)
> elif x in staff and not in uniqueStaff:
> uniqueStaff.append(x)
>
> When I try to import the module with th
orangeDinosaur <[EMAIL PROTECTED]> wrote:
> Here's a section of code:
>
> for x in occupants:
> if x not in uniqueUsers and not in staff: uniqueUsers.append(x)
> elif x in staff and not in uniqueStaff: uniqueStaff.append(x)
>
> When I try to import the module with the function definition th
Try:
for x in occupants:
if x not in uniqueUsers and x not in staff:
uniqueUsers.append(x)
elif x in staff and x not in uniqueStaff:
uniqueStaff.append(x)
--
http://mail.python.org/mailman/listinfo/python-list
Michael Tobis wrote:
>> $ rm `find . -name "*.pyc"`
>
> Ouch. Is that a true story?
Yup. Fortunately, it was a small, purely personal project, so it was no huge
loss. It was enough for me to start using CVS on my small, purely personal
projects, though!
--
Robert Kern
[EMAIL PROTECTED]
"I hav
[EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
...
> > 1) In Ruby there is a risk of "Variable/Method Ambiguity" when calling
...
> > 2) Ruby does not have true first-class functions living in the same
...
> > 4) Conclusion
...
> What happened to 3)?
I thought the OP was counting up by p
Francois <[EMAIL PROTECTED]> wrote:
...
> I guess my choice of words "rigor and consistency" was not very good.
> In this context "rigor" meant enforcing rules (for example having to
> use parentheses to call a method) to prevent ambiguity rather than
> depending on heuristics. Also "consistency
<[EMAIL PROTECTED]> wrote:
> thanks for the reply. I can see that there is a choice that needed to
> be made. Before I was aware of the \ issue I just used (yes it has
> come up, but the example is at work) triple quotes to work around the
> embedded quote issue:
>
> x=r'''It's like this "c:\bl
"Sandro Dentella" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> I'd like to understand why += operator raises an error while .append()
> does
> not.
Your mistake is thinking of '+=' as an operator. In Python terms it is
not, any more than '=' is. In Python, neither 'a=b' nor
Here's a section of code:
for x in occupants:
if x not in uniqueUsers and not in staff:
uniqueUsers.append(x)
elif x in staff and not in uniqueStaff:
uniqueStaff.append(x)
When I try to import the module with the function definition that
contains
> $ rm `find . -name "*.pyc"`
Ouch. Is that a true story?
While we're remeniscing about bad typos and DEC, I should tell the
story about the guy who clobberred his work because his English wasn't
very strong.
Under RT-11, all file management was handled by a program called PIP.
For example to
Alex Martelli wrote:
>
> I also share your preference for a single namespace for callable and
> non-callable values, as in Python (and Scheme, Lisp, C++, ...), rather
> than disjoint namespaces as in Ruby (and Smalltalk), but I do not see it
> as a question of rigor and consistency at all -- e.g.,
Bryan Olson wrote:
> Tuvas wrote:
> > Okay, I don't know if your farmiliar with the miller-rabin primality
> > test,
>
> Paul is familiar with it. When he referred to your Miller-Rabin
> test, he meant all the rounds.
>
> > but it's what's called a probabalistic test. Meaning that trying
> > it ou
"Michael Hoffman" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> wcc wrote:
>
>> Beginner learning Python here. I know filter(lambda x: x > 3, [1, 2,
>> 5, -3, 4, 8]) will give me a list [5, 4, 8]. What if I only need to
>> find the first item in the list that returns Ture when a
David Treadwell wrote:
> My ability to think of data structures was stunted BECAUSE of
> Fortran and BASIC. It's very difficult for me to give up my bottom-up
> programming style, even though I write better, clearer and more
> useful code when I write top-down.
That is also the case with Matla
I have found XMLUnit to be very helpful for testing Java and Jython code
that generates XML. At its heart XMLUnit is an XML-aware diff - it
parses expected and actual XML and pinpoints any differences. It is
smart enough to ignore things like attribute order, different quoting
and escaping styl
Robert Kern wrote:
> 1. Write grant proposals.
>
> 2. Advise and teach students.
Sorry I forgot the part about writing grant applications. As for
teaching students, I have thankfully not been bothered with that too
much.
> Yes, and this is why you will keep saying, "My simulation is running t
Astan Chee:
>I was wondering if there is a way to maximize CPU usage
Fork a Java app :-)
--
René Pijlman
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] wrote:
> What happened to 3)?
>
"4)" should have read "3)". I found the typo after I posted. I guess I
lack "rigor" myself !
--
http://mail.python.org/mailman/listinfo/python-list
Francois wrote:
> I discovered Python a few months ago and soon decided to invest time in
> learning it well. While surfing the net for Python, I also saw the hype
> over Ruby and tried to find out more about it, before I definitely
> embarked on studying and practicing Python. I recently found tw
Alex Martelli wrote:
>
> I also share your preference for a single namespace for callable and
> non-callable values, as in Python (and Scheme, Lisp, C++, ...), rather
> than disjoint namespaces as in Ruby (and Smalltalk), but I do not see it
> as a question of rigor and consistency at all -- e.g.,
Hi Steven,
thanks for the reply. I was/am aware that raw strings are mainly used
for regular expressions (and franky that was I usually use them for).
I was not aware that they still have "special powers" in raw strings
(thanks for the link!).
This one bit me when I was doing some quick and dirt
Hi Alex,
thanks for the reply. I can see that there is a choice that needed to
be made. Before I was aware of the \ issue I just used (yes it has
come up, but the example is at work) triple quotes to work around the
embedded quote issue:
x=r'''It's like this "c:\blah\" ok?'''
print x
It's like
Hi,
thanks for the reply. I was not aware of this in raw strings (and
frankly, don't like it... but who cares about that :-) )
When I needed embedded quotes in a raw string I went the triple quote
route:
a = r'''check \' this'''
which makes more sense to me.
--
http://mail.python.org/mailman
1 - 100 of 159 matches
Mail list logo