Gabriel Genellina wrote:
I see the point of the OP. Couldn't the new-line be used as an
equivalent of ':', for example, do you find this difficult to read:
if a == 3
do_something()
if a == 3: do_something()
Yes, it could be done, there are no technical reasons to always force to
use
On May 9, 10:10 am, [EMAIL PROTECTED] wrote:
> Hello all,
>
> I have a dictionary of which i'm itervalues'ing through, and i'll be
> performing some logic on a particular iteration when a condition is
> met with trusty .startswith('foo'). I need to grab the previous
> iteration if this condition i
[EMAIL PROTECTED] wrote:
The only thing is, is there is another natural meaning to [a,b:c].
Counting grids on the diagonals, the rational set is well defined:
0: 0, 0
1: 1, 0
2: 0, 1
3: 2, 0
4: 1, 1
5: 0, 2
6: 3, 0
7: 2, 1
...
Thencefore ( 2, 0 ) : ( 3, 0 ) is well defined. Thencefore,
a,b:
Viktor a écrit :
This completely slipped of my mind... :)
I'm trying to change the:
http://wordaligned.org/svn/etc/echo/echo.py
So if the function is method it prints ClassName.MethodName instead of
MethodName(self|klass|cls=<... ClassName>).
But it turned out that in the decorator, the wrappe
In article <[EMAIL PROTECTED]>,
Michael Torrie <[EMAIL PROTECTED]> wrote:
> [EMAIL PROTECTED] wrote:
> > Have a look at this:
> >
> -123**0
> > -1
> >
> >
> > The result is not correct, because every number (positive or negative)
> > raised to the power of 0 is ALWAYS 1 (a positive number
write working programs
> -Original Message-
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]
> Behalf Of [EMAIL PROTECTED]
> Sent: Thursday, May 08, 2008 6:25 AM
> To: python-list@python.org
> Subject: Newbie to python --- why should i learn !
>
>
> Hi,
>
> i was reading/learning s
You will not find a better watch copy for less
Every type and style
http://cunidezetoc62.blogspot.com
--
http://mail.python.org/mailman/listinfo/python-list
Thanks for the reply.
I've found and installed the package containing pvm3.h. (The file is
now located under "share/pvm3/include/pvm3.h".) But Pypvm can't find
it.
Someone recommended that I install the equivalent of what is called
"build-essential" in Ubuntu. I was told that the equivalent can b
In article <[EMAIL PROTECTED]>,
"Terry Reedy" <[EMAIL PROTECTED]> wrote:
> "Luis Zarrabeitia" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
> | Btw, there seems to be a math problem in python with exponentiation...
> | >>> 0**0
> | 1
> | That 0^0 should be a nan or exception, I g
XLiIV a écrit :
I started playing with Python and love it since the very beginning,
programming using Python is so ...human-like? but one thing returns to
me almost everytime when I see/write the code
Let's take a look at two ways of thinking...
the standard one which is well-known and loved by
Hello everyone I heard this was a good community to go too for help
and advice. I want to make a web site that uses the python programming
language which I am VERY new at. This website would store simple data
such as names in a form. At first I wanted to use mysql to store the
data but I want to ex
On Fri, 2008-05-09 at 15:08 +, Yves Dorfsman wrote:
> Gabriel Genellina wrote:
>
> >> I see the point of the OP. Couldn't the new-line be used as an
> >> equivalent of ':', for example, do you find this difficult to read:
> >>
> >> if a == 3
> >>do_something()
> >>
> >>
> >> if a == 3:
I had some very interesting results with this code to do what is asked:
for key in globals().keys():
del globals()[key]
for key in locals().keys():
del locals()[key]
It might be better to reverse the two steps, I didn't give it much thought.
Anyway, when this is done, all of the builtins
On May 9, 12:12 am, John Nagle <[EMAIL PROTECTED]> wrote:
> skunkwerk wrote:
> > i'm getting the wrong output for the 'title' attributes for this
> > data. the queue holds a data structure (item name, position, and list
> > to store results in). each thread takes in an item name and queries a
> >
On May 9, 4:09 pm, Paul Hankin <[EMAIL PROTECTED]> wrote:
> On May 9, 10:10 am, [EMAIL PROTECTED] wrote:
>
> > Hello all,
>
> > I have a dictionary of which i'm itervalues'ing through, and i'll be
> > performing some logic on a particular iteration when a condition is
> > met with trusty .startswit
On 9 Mai, 17:22, [EMAIL PROTECTED] wrote:
> Thanks for the reply.
>
> I've found and installed the package containing pvm3.h. (The file is
> now located under "share/pvm3/include/pvm3.h".) But Pypvm can't find
> it.
There is a pvm-dev package in Ubuntu, but it looks like Fedora employs
a different
Holden wrote:
> I want to make a web site that uses the python programming
> language which I am VERY new at. This website would store simple data
> such as names in a form. At first I wanted to use mysql to store the
> data but I want to export the data using xml.
>
> So say if a user logged in t
On Fri, 2008-05-09 at 08:39 -0700, Holden wrote:
> Hello everyone I heard this was a good community to go too for help
> and advice. I want to make a web site that uses the python programming
> language which I am VERY new at. This website would store simple data
> such as names in a form. At first
In article <[EMAIL PROTECTED]>,
maxinbjohn <[EMAIL PROTECTED]> wrote:
>Hi Raxit,
>
>One of the the tempting features of Python is that it is fun to code
>in Python. If you are really trying to learn python, you should read
>Adventures with Neko (http://gnuvision.com/books/pybook/) . It is an
>intr
On May 8, 3:09 pm, "Terry Reedy" <[EMAIL PROTECTED]> wrote:
> "Szabolcs Horvát" <[EMAIL PROTECTED]> wrote in message
>
> news:[EMAIL PROTECTED]| Gabriel Genellina wrote:
>
> | >
> | > Python doesn't require __add__ to be associative, so this should not be
> used as a general sum replacement.
> |
>
Best Video sexi !! *-*!!
http://rozrywka.yeba.pl/show.php?id=2073
http://rozrywka.yeba.pl/show.php?id=2079
--
http://mail.python.org/mailman/listinfo/python-list
"Terry Reedy" <[EMAIL PROTECTED]> wrote:
>
> "Szabolcs Horvát" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
>| Gabriel Genellina wrote:
>| >
>| > Python doesn't require __add__ to be associative, so this should
>| > not be
> used as a general sum replacement.
>|
>| It does not
On May 9, 11:52 am, Marc 'BlackJack' Rintsch <[EMAIL PROTECTED]> wrote:
> Maybe it's also harder to read than this::
>
> print '-'.join(map(str, time.localtime()[:3]))
I like this concept, it's so, .. ziped :)
> Of course, if you don't mind the extra padding zeroes in day and month::
>
> prin
Hi,
The wikipedia article on Duck Typing has this criticism section that
needs a citation:
(Fron: http://en.wikipedia.org/wiki/Duck_typing#Criticism)
An often cited criticism is this:
One issue with duck typing is that it forces the programmer to
have a much wider understanding of the code he
-
(Apologies for cross-posting)
Special Track “Computational Bioimaging and Visualization”
International Symposium on Visual Computing (ISVC08)
Las Vegas, Nevada
rynt wrote:
Hello all.
I'm Looking for suggestions for which Python web framework(e.g.
Django, Turbogears,etc.) would work best to develop a cross platform
browser based system to manage lab specimens.
Requirements are:
a. highly secure
b. run on internet or intranet
e. RDBMS read/write intensi
On May 9, 6:30 pm, Paddy <[EMAIL PROTECTED]> wrote:
> Hi,
> The wikipedia article on Duck Typing has this criticism section that
> needs a citation:
> (Fron:http://en.wikipedia.org/wiki/Duck_typing#Criticism)
>
> An often cited criticism is this:
> One issue with duck typing is that it forces t
On May 9, 1:45 am, [EMAIL PROTECTED] wrote:
> >>> key = ''.join(sorted(word))
>
> I tend to strip and lower the word as well, otherwise "Hello" and
> "hello" do not compare...depends on what you want though!
> Plus you might get a lot of "word\n" as keys...
>
> My technique is the this way
>
> def
Hi all,
This is my first post and I'm really at a loss for how to fix my
problem, so I really hope someone can help me out.
I am working on a web application using Pylons .0.9.6, SQLAlchemy 0.4.4,
MySQLdb 1.2.2 and Python 2.4.4.
We want to use utf8 encoding throughout and as far as I ca
"Lou Pecora" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| In article <[EMAIL PROTECTED]>,
| "Terry Reedy" <[EMAIL PROTECTED]> wrote:
|
| > "Luis Zarrabeitia" <[EMAIL PROTECTED]> wrote in message
| > news:[EMAIL PROTECTED]
| > | Btw, there seems to be a math problem in python with
[EMAIL PROTECTED] writes:
> On May 9, 1:45 am, [EMAIL PROTECTED] wrote:
>> >>> key = ''.join(sorted(word))
>>
>> I tend to strip and lower the word as well, otherwise "Hello" and
>> "hello" do not compare...depends on what you want though!
>> Plus you might get a lot of "word\n" as keys...
>>
>> M
Am Freitag 09 Mai 2008 10:19:45 schrieb Bruno Desthuilliers:
> >> very often sees do-nothing catch-all try/catch blocks in Java -
> >> which is way worse than just letting the exception propagate. I
> >> find all this totally pointless, because there's just no way for a
> >> compiler to check if y
"XLiIV" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
Pipelining works best when all functions have just one input.
But that is a small subset of actual programs.
--
http://mail.python.org/mailman/listinfo/python-list
"Christian Heimes" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
| Kay Schluehr schrieb:
| > http://www.python.org/ftp/python/3.0/python-3.0a5.msi
|
| > Error 404: File Not Found
|
| > http://www.python.org/ftp/python/3.0/python-3.0a5.amd64.msi
|
| > Error 404: File Not Found
|
| Th
"Gabriel Genellina" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
En Fri, 09 May 2008 07:58:33 -0300, Banibrata Dutta
<[EMAIL PROTECTED]> escribió:
|> I already have Python25, and need to install Python24. I would prefer
not to
|> remove Python25, but each Python version seems to
I need to know how to call a text file called txt_file.do I just put the
directory that it is in like C:\documnet\blah\blah ???
cars_file = open()
# i will be our line counter so we know when to pause
i = 0
print
for line in cars_file:
i = i + 1 # increment i by 1 at each line
prin
"grbgooglefan" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
|I am creating functions, the return result of which I am using to make
| decisions in combined expressions.
| In some expressions, I would like to inverse the return result of
| function.
|
| E.g. function contains(source
On May 9, 10:11 am, Yves Dorfsman <[EMAIL PROTECTED]> wrote:
> [EMAIL PROTECTED] wrote:
> > The only thing is, is there is another natural meaning to [a,b:c].
>
> > Counting grids on the diagonals, the rational set is well defined:
>
> > 0: 0, 0
> > 1: 1, 0
> > 2: 0, 1
> > 3: 2, 0
> > 4: 1, 1
> > 5
Lawrence, Anna K (US SSA) wrote:
I am working on a web application using Pylons .0.9.6, SQLAlchemy 0.4.4,
MySQLdb 1.2.2 and Python 2.4.4.
We want to use utf8 encoding throughout and as far as I can see
everything is set properly between components and I’ve got a
sitecustomize.py in my site-pa
Hello Everyone,
I've been looking into writing a utility to compare/analyse xml files, and
thought I'd have a look at PyXml, but the Sourceforge page says it's no
longer maintained.
Two questions:
What's the story with PyXml? Is it stable/complete or has effort moved
elsewhere?
Can anyone recom
> > What would be the best method to print the top results, the one's that
> > had the highest amount of anagrams?? Create a new histogram dict?
>
> You can use the max() function to find the biggest list of anagrams:
>
> top_results = max(anagrams.itervalues(), key=len)
>
> --
> Arnaud
That is t
If I have a property in a derived class, it is difficult to override
the get and set functions: the property's function object had early
binding, whereas the overriden method was bound late.
This was previously discussed:
http://groups.google.com/group/comp.lang.python/browse_thread/thread/e13a
Best Viedo! SEXI *-*!!
http://rozrywka.yeba.pl/show.php?id=2079
http://rozrywka.yeba.pl/show.php?id=2073
--
http://mail.python.org/mailman/listinfo/python-list
On Thu, 8 May 2008 22:38:44 -0700, "Waylen Gumbal" <[EMAIL PROTECTED]>
wrote:
>Sherman Pendley wrote:
>> [EMAIL PROTECTED] writes:
>> >
>> > > PLEASE DO NOT | :.:\:\:/:/:.:
>> > > FEED THE TROLLS | :=.' - - '.=:
>> >
>> > I don't think Xah is trolling here (contrary to his/her habit)
>> > but posi
Joseph Turian wrote:
If I have a property in a derived class, it is difficult to override
the get and set functions: the property's function object had early
binding, whereas the overriden method was bound late.
This was previously discussed:
http://groups.google.com/group/comp.lang.python/br
i want to a little stringmanipulationa nd im looking into regexps. i
couldnt find out how to do:
s = 'poprorinoncoce'
re.sub('$o$', '$', s)
should result in 'prince'
$ is obv the wrng character to use bu what i mean the pattern is
"consonant o consonant" and should be replace by just "consonant".
On Sat, 10 May 2008 07:19:38 +1000, <[EMAIL PROTECTED]> wrote:
> What would be the best method to print the top results, the one's that
> had the highest amount of anagrams?? Create a new histogram dict?
You can use the max() function to find the biggest list of anagrams:
top_results = max(an
On May 9, 5:19 pm, globalrev <[EMAIL PROTECTED]> wrote:
> i want to a little stringmanipulationa nd im looking into regexps. i
> couldnt find out how to do:
> s = 'poprorinoncoce'
> re.sub('$o$', '$', s)
> should result in 'prince'
>
> $ is obv the wrng character to use bu what i mean the pattern i
On Fri, May 9, 2008 at 3:20 PM, Joseph Turian <[EMAIL PROTECTED]> wrote:
> Could someone demonstrate how to implement the proposed solutions that
> allow the property to be declared in the abstract base class, and
> refer to a get function which is only implemented in derived classes?
One way is t
On May 9, 3:19 pm, globalrev <[EMAIL PROTECTED]> wrote:
> i want to a little stringmanipulationa nd im looking into regexps. i
> couldnt find out how to do:
> s = 'poprorinoncoce'
> re.sub('$o$', '$', s)
> should result in 'prince'
>
> $ is obv the wrng character to use bu what i mean the pattern i
> What's the story with PyXml? Is it stable/complete or has effort moved
> elsewhere?
Large parts of PyXML are now part of the standard library. When I
stepped back as a maintainer, nobody volunteered to take over.
> Can anyone recommend a Python validating parser that validates vs Xml
> Schema?
I'm running python 2.5.2 on WinXP. I've always used a GUI for
interactive development, but I wanted to try out ipython which better
supports matplotlib in this mode. Unfortunately, whenever I try to
use help() I get the following error:
(Sys) The system cannot find the file specified.
"C:\docum
Paul McGuire wrote:
from re import *
Perhaps you intended "import re".
vowels = "aAeEiIoOuU"
cons = "bcdfghjklmnpqrstvwxyzBCDFGHJKLMNPQRSTVWXYZ"
encodeRe = re.compile(r"([%s])[%s]\1" % (cons,vowels))
print encodeRe.sub(r"\1",s)
This is actually a little more complex than you asked - it will
ty. that was the decrypt function. i am slo writing an encrypt
function.
def encrypt(phrase):
pattern =
re.compile(r"([bcdfghjklmnpqrstvwxyzBCDFGHJKLMNPQRSTVWXYZ])")
return pattern.sub(r"1\o\1", phrase)
doesnt work though, h becomes 1\\oh.
def encrypt(phrase):
pattern =
re.compile(r
Law enforcement is now intercepting text messages,
as proven by Operation Sudden Fall in San Diego.
http://www.usdoj.gov/dea/pubs/states/newsrel/sd050608.html
http://www.signonsandiego.com/news/education/20080506-1338-bn06sdsu2.html
Don't let your personal SMS/text messages fall into
the wrong ha
On May 9, 5:19 pm, [EMAIL PROTECTED] wrote:
> > > What would be the best method to print the top results, the one's that
> > > had the highest amount of anagrams?? Create a new histogram dict?
>
> > You can use the max() function to find the biggest list of anagrams:
>
> > top_results = max(anagra
> On 9 Mai, 01:50, Barry Warsaw <[EMAIL PROTECTED]> wrote:
> > On behalf of the Python development team and the Python community, I
> > am happy to announce the third alpha release of Python 2.6, and the
> > fifth alpha release of Python 3.0.
After I installer Python 2.6a3, Matlab R2007a began ha
On May 9, 5:20 pm, Joseph Turian <[EMAIL PROTECTED]> wrote:
> If I have a property in a derived class, it is difficult to override
> the get and set functions: the property's function object had early
> binding, whereas the overriden method was bound late.
> This was previously discussed:
> http
globalrev wrote:
ty. that was the decrypt function. i am slo writing an encrypt
function.
def encrypt(phrase):
pattern =
re.compile(r"([bcdfghjklmnpqrstvwxyzBCDFGHJKLMNPQRSTVWXYZ])")
The inner pair of () are not necessary.
return pattern.sub(r"1\o\1", phrase)
doesnt work though, h b
On May 9, 7:55 pm, Stéphane Larouche <[EMAIL PROTECTED]>
wrote:
> > On 9 Mai, 01:50, Barry Warsaw <[EMAIL PROTECTED]> wrote:
> > > On behalf of the Python development team and the Python community, I
> > > am happy to announce the third alpha release of Python 2.6, and the
> > > fifth alpha release
On May 8, 7:50 pm, Barry Warsaw <[EMAIL PROTECTED]> wrote:
> On behalf of the Python development team and the Python community, I
> am happy to announce the third alpha release of Python 2.6, and the
> fifth alpha release of Python 3.0.
>
> Please note that these are alpha releases, and as suc
Incidentally, now that everyone knows English, writer would like to
critique his behavior. I have leaned to the group for approval, at
times by disparaging the efforts of others, but other times not. I
have expressed negative emotion. Is anyone in earshot getting work
done that I am interfering
> The inner pair of () are not necessary.
yes they are?
ty anyway, got it now.
--
http://mail.python.org/mailman/listinfo/python-list
Brian Vanderburg II <[EMAIL PROTECTED]> wrote:
>D'Arcy J.M. Cain wrote:
>> Brian Vanderburg II <[EMAIL PROTECTED]> wrote:
>>
>>> This is sort of related, but I'm wondering what is different between
>>> "#!/usr/bin/env python" and "#!python". Wouldn't the second do the same
>>> thing, since an
On 2008-05-09 18:53:19 -0600, George Sakkis <[EMAIL PROTECTED]> said:
On May 9, 5:19 pm, [EMAIL PROTECTED] wrote:
What would be the best method to print the top results, the one's that
had the highest amount of anagrams?? Create a new histogram dict?
You can use the max() function to fin
George Neuner wrote:
+---
| Common Lisp doesn't have "filter".
+---
Of course it does! It just spells it REMOVE-IF-NOT!! ;-} ;-}
> (remove-if-not #'oddp (iota 10))
(1 3 5 7 9)
> (remove-if-not (lambda (x) (> x 4)) (iota 10))
(5 6 7 8 9)
>
-Rob
globalrev wrote:
The inner pair of () are not necessary.
yes they are?
You are correct. I was having a flashback to a dimly remembered previous
incarnation during which I used regexp software in which something like
& or \0 denoted the whole match (like MatchObject.group(0)) :-)
--
http://
On May 9, 6:52 pm, John Machin <[EMAIL PROTECTED]> wrote:
> Paul McGuire wrote:
> > from re import *
>
> Perhaps you intended "import re".
Indeed I did.
>
>
> > Both print "prince".
>
> No they don't. The result is "NameError: name 're' is not defined".
Dang, now how did that work in my script?
Thanks, Gabriel and Terry, for your responses.
Another somewhat realted, but very noob'ish question --
given that I already have Python2.5 installed & will install Python2.4, will
copying the ../Lib/site-packages/ from 2.5 into 2.4's, work ?
i think the answer is "no", but still asking. is it pac
I'm still having trouble with calling a text file and I know its so simple
here is the code
work = open('C:\Documents and Settings\Administrator\My
Documents\Chris\Python\Python\work.txt', 'r')
for line in work.txt:
print line
---
Any guesses as to how many people are still using Tkinter? And can
anyone direct me to good, current docs for Tkinter?
Thanks,
Ken
--
http://mail.python.org/mailman/listinfo/python-list
Martin v. Löwis wrote:
>> Can anyone recommend a Python validating parser that validates vs Xml
>> Schema?
>
> The libxml bindings for Python can do that.
... although the OP will likely prefer using lxml, where it's three lines of
Python (ok, plus an import), compared to quite a bit of code in t
In the past weeks i've been thinking over the problem on the practical
problems of regex in its matching power. For example, often it can't
be used to match anything of nested nature, even the most simple
nesting. It can't be used to match any simple grammar expressed by
BNF. Some rather very regul
Is it possible to coax python to find more than one error at once?
Thanks,
Joseph
--
http://mail.python.org/mailman/listinfo/python-list
On Sat, 10 May 2008 00:20:33 -0500, Kenneth McDonald wrote:
> Any guesses as to how many people are still using Tkinter? And can
> anyone direct me to good, current docs for Tkinter?
AFAIK `Tkinter` hasn't changed much over time, so "old" documentation is
still current.
Ciao,
Marc 'Bla
101 - 175 of 175 matches
Mail list logo