notbob wrote:
frustrated and give up on learning programming, not really caring much for
coding, anyway. But, dammit, I'm gonna stick with it this time. I'll learn
python if it kills me!
No, it won't kill you but make you stronger ;)
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] wrote:
Is that true that this comparison operators are gone in Python 3.0:
<(is less than)
(is greater than)
<= (is less than or equals)
= (is greater than or equals)
Is it true?
Nope.
--
http://mail.python.org/mailman/listinfo/python-list
alefajnie wrote:
class B:
this_is_common_for_all_instances = []
def __init__(self, v):
self.this_is_common_for_all_instances.append(v)
now I can create some instances of B, but all of them have the same
array, why
Because you didn't reassign the attribute
'this_is_
[EMAIL PROTECTED] wrote:
We have to avoid the use of the 'is' identity operator with basic,
immutable values such as numbers and strings.
I'm glad for you. Did you really write checks like "if foo is 27" ?
The point is, you have to learn technologies to use them. It's not like
technologies l
alex23 wrote:
Given that all nine of his postings have inflammatory topics, he's
beginning to sound like a troll.
Thank you, I couldn't decide if he was silly or nasty.
Now I know he's both.
--
http://mail.python.org/mailman/listinfo/python-list
Kees Bakker wrote:
So far, I have seen only one editor that understands the difference between
TABs and indentation, and that is Emacs.
Oh, well... in .vimrc:
autocmd FileType python set tabstop=8
autocmd FileType python set softtabstop=4
autocmd FileType python set expandtab
--
asdfdg--
http://mail.python.org/mailman/listinfo/python-list
Hy guys,
I'm using the python-framework BeautifulSoup(BS) to parse some
information out of a german soccer-website.
I spend some qualitiy time with the BS-docs, but I couldn't really
figure out how to get what I was looking for.
Here's the deal:
I want to parse the article shown on the website. T
I would like to point you to this post readed some days ago got from
planet python
I search inside this group but I didn't find anything related (am I
wrong?)
anyway here it is,
http://sayspy.blogspot.com/2008/06/i-cant-build-python-using-llvm.html
I've more or less the same questions reported in t
Daniel Fetchinson wrote:
> This is a quick poll to have scientific data on our beloved troll community:
>
> Whose trolling behaviour is more professional? (check one)
You forgot to mention Ilias Lazaridis. He needs to be Analyzed and
Evaluated, too.
--
http://mail.python.org/mailman/listinfo
Steve Holden wrote:
>> the XML file is almost a TB in size...
>>
> Good grief. When will people stop abusing XML this way?
Not before somebody writes a clever xmlfs for the linux kernel :-/
--
http://mail.python.org/mailman/listinfo/python-list
Marco Mariani wrote:
>>> the XML file is almost a TB in size...
>>>
>> Good grief. When will people stop abusing XML this way?
>
> Not before somebody writes a clever xmlfs for the linux kernel :-/
Ok.
I meant it as a joke, but somebody has been there
Bruno Desthuilliers wrote:
> sig=lambda m:'@'.join(['.'.join([w[::-1] for w in p.split('.')]) for p
> in m.split('@')])
Pff... you call that a quicksort?
From http://www.p-nand-q.com/python/obfuscated_python.html
import sys
funcs = range(10)
def A(_,o):
_[3]=_[5]()
def B(_,o):
Bruno Desthuilliers wrote:
> sig=lambda m:'@'.join(['.'.join([w[::-1] for w in p.split('.')]) for p
> in m.split('@')])
Pff... you call that a quicksort?
From http://www.p-nand-q.com/python/obfuscated_python.html
import sys
funcs = range(10)
def A(_,o):
_[3]=_[5]()
def B(_,o):
Bruno Desthuilliers wrote:
>> Pff... you call that a quicksort?
>>
> Nope, only somewhat obfuscated Python. And it seems it's at least
> obfuscated enough for you to believe it could be a quicksort
> implementation !-)
You're right, but I'm past the quine age and don't bother parsing
obfuscate
Tim Golden wrote:
> I've recently used Elixir and found it very useful for a small-scale
> database with no more than a dozen tables, well-structured and
> easily understood. I'd certainly use it again for anything like that
> to save me writing what would amount to boilerplate SQL. But I'd
> hate
Bruno Desthuilliers wrote:
>> A simple select query would be db.select('customers') or
>> db.select('customers', name='John').
>> But you can also resort to plain sql as follows: db.query('select *
>> from customers where name = "John"').
>>
>> Simple, effective and doesn't get in your way.
>
> S
installers:
http://www.bonifazi.eu/appunti/2008/04/pygtk-all-in-one-installer.html
I'll try to keep update this installer.
I hope it could be useful to someone.
Bye.
Marco Bonifazi
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] wrote:
> Which one do you think will educate me the best?
Advanced javascript might teach you something too, and be very useful at
the same time.
Take a look at the Crockford lessons on Yahoo! Video.
http://video.yahoo.com/watch/111593
http://video.yahoo.com/watch/111594
htt
Penny Y. wrote:
> Javascript is different from Java at all.
I think even rocks know that. Yet, some use of closure and
prototype-based inheritance might be interesting to the OP.
> Why not Perl?
Come on, learning Perl after two years of Python? How harsh.
> Perl is a functional language,
And
Aaron Watters wrote:
> stuff out there you can get so easily -- all the stuff that py3k
> will break -- most of which won't get ported -- and if it does can
> we be sure it will be tested properly? No, probably you will end
> up beta testing someone's quick port of what used to be rock
> solid co
Torsten Bronger wrote:
>>> If I were you I would keep it a secret until a Hollywood producer
>>> offers big bucks for the film rights.
>> Who would play Guido, I wonder?
>
> Ralf Möller. No other.
And the GIL killer?
Clive Owen, Matt Damon, Mark Wahlberg?
--
http://mail.python.org/mailman/lis
[EMAIL PROTECTED] wrote:
> Yes, it makes it more readable. And yes, it does make it (a lot) more
> maintainable. Mainly because I don't have those four variables, I have
> about thirty. And I think I won't need to one or two of them, but
> maybe all of them at once.
have fun with locals(), then (
azrael wrote:
Please give me any arguments to cut him down about his commnets
like :"keep programing i python. maybe, one day, you will be able to
program in VisualBasic"
This hurts. Please give me informations about realy famous
aplications.
He's joking. Perl is a dysfunctional language and
Jens wrote:
I've the checked that i'm referring to the variables correctly, so the
only explanation i can come up with, is that '+' doesn't result in a
string concatenation (with implicit typecast to string of the integer
variable(this is a interpreted language after all)).
No, sorry. You real
Jens wrote:
You might have wrong assumptions from previous PHP experiences.
>>> 'x'+4
Traceback (most recent call last):
File "", line 1, in
TypeError: cannot concatenate 'str' and 'int' objects
>
... and the non snobby answer would have been:
...
Sorry. Not trying to be snobbish,
Jens wrote:
Hey no worriest. Is this the tutorial you're referring to:
http://docs.python.org/lib/typesmapping.html
Is there anything better?
That's the library reference - the one to keep under the pillow.
It also documents the core -- i.e. builtin objects.
As for the language semantics,
Torsten Bronger wrote:
However, join() is really bizarre. The list rather than the
separator should be the leading actor.
No, because join must work with _any sequence_, and there is no
"sequence" type to put the join method on.
This semantic certainly sets python apart from many other lang
Gasto wrote:
> I still don't see why such a module exists.
There are 2.0 types of programmers: those who always use floating point,
and those who know how to use them.
--
http://mail.python.org/mailman/listinfo/python-list
Boris Borcic wrote:
One way :
>>> from functools import partial
>>> def func(item) : print item
>>> llist = [partial(func,item) for item in range(5)]
>>> for thing in llist : thing()
0
1
2
3
4
Another way:
class Func(object):
def __init__(self, item):
self.item = item
Raymond wrote:
Aren't sed, awk, grep, and perl the reference implementations of search
and replace?
I don't know about "reference implementations", but I daresay they are a
mess w.r.t. usability.
--
http://mail.python.org/mailman/listinfo/python-list
Duncan Booth wrote:
It does this:
@greedy
def getCommandsFromUser():
while True:
yield raw_input('Command?')
for cmd in getCommandsFromUser():
print "that was command", cmd
Command?hello
Command?goodbye
that was command hello
Comma
Marco Mariani wrote:
Not here..
Oh, sorry, I obviously didn't see the @greedy decorator amongst all the
quoting levels.
Anyway, the idea doesn't make much sense to me :)
--
http://mail.python.org/mailman/listinfo/python-list
Duncan Booth wrote:
Perhaps if you'd copied all of my code (including the decorator that was
the whole point of it)...
Sure, I missed the point. Python's > symbols become quoting levels and
mess up messages.
Anyway, I would loathe to start execution of a generator before starting
to iterat
Lucas Prado Melo wrote:
How could I "prove" to someone that python accepts this syntax using
the documentation (I couldn't find it anywhere):
classname.functionname(objectname)
TUtorial 9.3.4, method objects
What exactly happens when a method is called? You may have noticed that
x.f() was ca
Is there a program (free, payware, whatever) like polystyle for
linux/python?
http://www.polystyle.com/features/python-beautifier.jsp
I've never used it, but the example is quite clear.
I just need it for python -- but it should not force me to use PEP8.
--
http://mail.python.org/mailman/lis
[EMAIL PROTECTED] wrote:
The default way of killing the current process on the command line is
Ctrl+C, but that doesn't work with Python.
It should work.
Do you have a bare except: which intercepts SystemExit as well?
If so, be as specific as possible in what you intercept, or at least
catc
://www.sqlalchemy.org/
These can assist in translating SQL query results into Python objects.
For generating the html forms and tables out of the sql results data
you
can try:
genshi: http://genshi.edgewall.org/
kid: http://www.kid-templating.org/
I hope this helps.
Marco
--
http://ma
hould help you here:
>
> http://python-mock.sourceforge.net/
>
> There's even an example on that page for mocking a database.
> --
> http://mail.python.org/mailman/listinfo/python-list
>
--
Marco Bizzarri
http://iliveinpisa.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
ainful, and leads you to frustration
when the actual SQL and the generated SQL do not match.
Regards
Marco
--
Marco Bizzarri
http://iliveinpisa.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
atabase (or whatever external resource you want to access), and,
after that, it should be transparent for you, more or less.
Regards
Marco
--
Marco Bizzarri
http://iliveinpisa.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
On Tue, Aug 26, 2008 at 8:33 PM, frankrentef <[EMAIL PROTECTED]> wrote:
>
> Would the second file need something akin to...
>
> loginout.admin (ie,url,adminlogin)
Yes. Since you're importing the whole module.
--
Marco Bizzarri
http://iliveinpisa.blogspot.com/
--
On Wed, Aug 27, 2008 at 10:26 AM, Simon Brunning
<[EMAIL PROTECTED]> wrote:
> 2008/8/27 Marco Bizzarri <[EMAIL PROTECTED]>:
>> I strongly disagree on using mocks for a database; checking sequences
>> of SQL statement is fragile, painful, and leads you to frustration
>
d. However, when I execute the code from the command line, I
> get the following error:
>
> ImportError: No module named mypackage.unittests.test1
>
1) What is the command you're using to run the alltest.py module?
2) what is the result of:
- python -c
o/python-list
>
Have you tried to use ldd against the _libfoo.so to check if it is
able to get all the libraries it needs?
Regards
Marco
--
Marco Bizzarri
http://iliveinpisa.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
a flat module)
or
from package.subpackage import module
and then use
module.MyClass
(( for a package/subpackage structure ))
Thank you all for your attention
Regards
Marco
--
Marco Bizzarri
http://iliveinpisa.blogspot.com/
http://notenotturne.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
her possibility, which you can check googling a little, is that
you've two different versions of the libarary around your system, and
that you're loading the wrong one (i.e., python is looking at the
wrong one)
again, setting the LD_LIBRARY_PATH should help
Regards
Marco
On Sat, Aug 30,
m, also,
because I think it has to do with your setup (not that you setup
something in the wrong way: just to have context).
Regards
Marco
--
Marco Bizzarri
http://iliveinpisa.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
ks Fredrik; I understand that is the underlying message of your article.
I'm just confused because PEP8 seems to suggest that the from module
import Class style is acceptable; is there a big "if you know what are
doing" before, which I'm unable to see?
Regards
Marco
--
nction/method (or even in
> their argument list, but that's a hack to be used only once in a
> while):
> localname = somemodule.somename
>
> Bye,
> bearophile
> --
> http://mail.python.org/mailman/listinfo/python-list
>
Thanks again for sharing your thoughts with
mport datetime # This might be a bad idea... I haven't
> had problems yet though. datetime.datetime gets on my nerves though.
>
> just my .02
>
> Eric
> --
> http://mail.python.org/mailman/listinfo/python-list
>
Thanks Eric; your 02 cents are worthy for me ;)
Regards
Marco
--
Marco Bizzarri
http://iliveinpisa.blogspot.com/
http://notenotturne.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
will be calculated in the process).
> I've been searching, but couldn't find any examples which allows that.
Is it suitable for you to use a python program talking with a running
instance of openoffice? in that case, pyuno could help you.
--
Marco Bizzarri
http://notenotturn
>
> Does anyone have any experience with this sort of thing? If so, could
> you suggest a good library and possibly some samples?
Isn't the SAX part of this howto
http://pyxml.sourceforge.net/topics/howto/xml-howto.html
enough for you to create your parser?
Regards
Marco
--
M
oes the HTTPConnection object have a property that stores this ?
> or is it retrievable by some other form?
>
> Thanks a lot.
> --
Looking at the code of HTTPConnection, all that goes through the
_output message (including, therefore, the putheaders) are appended to
the self._buffer l
in your snippet of code, if encoding is latin1, at least for
what I can understand.
Do not assume utf8 is a two byte encoding; utf8 is a variable length
encoding. Indeed,
'a' encoded as utf8 is 'a' (one byte)
'à' encode as utf8 is '\xc3\xa0'
encode('utf8')
I'm assuming here that the urlib.unquote(c.user.firstName) returns an
encodable string (which I'm absolutely not sure), but if it does, this
should take the first 'character'.
Regards
Marco
--
Marco Bizzarri
http://notenotturne.blogspot.com/
http://iliveinpisa.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
error:
>
> socket.gaierror: (11001, 'getaddrinfo failed')
>
> Do you know what I do wrong?
> Thank you very much.
>
>
localhost is not resolved to 127.0.0.1 on your machine.
Try changing it to http://127.0.0.1:8080
Regards
Marco
--
Marco Bizzarri
http://notenotturne.blogspot.com/
http://iliveinpisa.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
st?
> --
> http://mail.python.org/mailman/listinfo/python-list
>
I do not think I qualify for experienced users; I've used pydev for
many years, and I'm quite comfortable with it. It is an eclipse based
IDE, therefore you've some of its niceties and some of its dra
source, maybe you could create a subclass of Set
redefining the __contains__ method?
Regards
Marco
--
Marco Bizzarri
http://notenotturne.blogspot.com/
http://iliveinpisa.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
s,
> Wojtek Walczak,
> http://tosh.pl/gminick/
> --
> http://mail.python.org/mailman/listinfo/python-list
>
Saluti
Marco
--
Marco Bizzarri
http://notenotturne.blogspot.com/
http://iliveinpisa.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
plication. Using Python. I found "Dive
>> Into Python" which I will be reading shortly.
>>
>So one question: what RDBMs are supported in that space?
The appearance is not an RDBMS, at least, maybe it is, but under the surface.
Looks more that y
Let's say I've a class a, where I can write:
--
Marco Bizzarri
http://notenotturne.blogspot.com/
http://iliveinpisa.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
On Thu, Sep 4, 2008 at 1:00 PM, Diez B. Roggisch <[EMAIL PROTECTED]> wrote:
> Marco Bizzarri wrote:
>
>> Let's say I've a class a, where I can write:
>
> Anticipating this obviously premature posting:
>
> http://dirtsimple.org/2004/12/python-is-not-java.htm
r
all, if it is wrong, I can move to a language like Java, which has a
different approach on it. I'm really very interested in reading past
discussion on it, if they are available.
Regards
Marco
On Thu, Sep 4, 2008 at 12:57 PM, Marco Bizzarri
<[EMAIL PROTECTED]> wrote:
> Let's sa
org/mailman/listinfo/python-list
>
Thanks for the pointer, Bruno... I wrote from my memory, but there is
some bank of it which need quick replace ;)
--
Marco Bizzarri
http://notenotturne.blogspot.com/
http://iliveinpisa.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
On Thu, Sep 4, 2008 at 3:07 PM, Maric Michaud <[EMAIL PROTECTED]> wrote:
> Le Thursday 04 September 2008 14:31:23 Michele Petrazzo, vous avez écrit :
>> Marco Bizzarri wrote:
>> > looking at the source, maybe you could create a subclass of Set
>> > redefining th
On Thu, Sep 4, 2008 at 1:19 PM, Diez B. Roggisch <[EMAIL PROTECTED]> wrote:
>
> What you are essentially asking is: why is python dynamic instead of static?
>
Most probably you're right. Maybe I will make a trip back to my
university books and take a look at them aga
On Thu, Sep 4, 2008 at 4:39 PM, Marco Bizzarri <[EMAIL PROTECTED]> wrote:
>
> Most probably you're right. Maybe I will make a trip back to my
> university books and take a look at them again :-)
>
Meant: you *are* right. Sorry.
Saluti
Marco
--
Marco Bizzarri
http://no
On Thu, Sep 4, 2008 at 2:43 PM, Bruno Desthuilliers
<[EMAIL PROTECTED]> wrote:
Well, Bruno, it looks like I've to wider my search in order to read
something about it. Thanks for your suggestions, in any case.
Regards
Marco
--
Marco Bizzarri
http://notenotturne.blogspo
re, if I want them, I will go for Java, or some other
language like that.
I understand that Python is a balance between different forces (like
any software object around the world) and I'm simply asking some
pointers to the discussion leading to this balance.
That's all.
--
Marco Bizzarri
http://notenotturne.blogspot.com/
http://iliveinpisa.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
typo.
>
>
> --
> Stand Fast,
> tjg. [Timothy Grant]
>
Right; that is one of the things I try to do to avoid this sort of problems.
--
Marco Bizzarri
http://notenotturne.blogspot.com/
http://iliveinpisa.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
a debug-enabled python in order to have more meaningful
backtraces?
- is there something else I should do in order to have more clues
("Read The Fine Manual (tm)" is an acceptable answer)
Regards
Marco
--
Marco Bizzarri
http://notenotturne.blogspot.com/
http://iliveinpisa.blogspot.com/
On Fri, Sep 5, 2008 at 3:50 PM, Maric Michaud <[EMAIL PROTECTED]> wrote:
> Le Friday 05 September 2008 15:04:22 Marco Bizzarri, vous avez écrit :
>> Hi all.
>>
>> I'm experiencing a core dump while working in the following environment
>>
>> - debain
On Thu, Sep 4, 2008 at 10:47 AM, Fredrik Lundh <[EMAIL PROTECTED]> wrote:
>
> (...as Bruno implies, setattr(), len() et al can be and should be viewed as
> generic functions.
Just a question: "generic functions" are not meant in the sense of
"generic functions&qu
On Fri, Sep 5, 2008 at 9:16 PM, Bruno Desthuilliers
<[EMAIL PROTECTED]> wrote:
> Marco Bizzarri a écrit :
>>
>> Just a question: "generic functions" are not meant in the sense of
>> "generic functions" of CLOS, am I right?
>
> Nope. Ju
On Sat, Sep 6, 2008 at 7:52 AM, Fredrik Lundh <[EMAIL PROTECTED]> wrote:
> Marco Bizzarri wrote:
>
>>> (...as Bruno implies, setattr(), len() et al can be and should be viewed
>>> as
>>> generic functions.
>>
>> Just a question: "gene
%s " % self.testsRun)
_TextTestResult.startTest(self, test)
now, of course, this is ugly, because I'm using _TextTestResult, which
I'm not supposed to know, and I'm changing behaviour by subclassing,
which is not exactly what I would like to do.
What is the pythonic way to accompl
point me in the right
> direction from where to start?
>
> Thanks in advance!
> --
> http://mail.python.org/mailman/listinfo/python-list
>
http://www.modpython.org/
Regards
Marco
--
Marco Bizzarri
http://notenotturne.blogspot.com/
http://iliveinpisa.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
On Wed, Sep 10, 2008 at 3:25 PM, Diez B. Roggisch <[EMAIL PROTECTED]> wrote:
> Marco Bizzarri wrote:
>
>> Hi all.
>>
>> I would like to change the way test reports are generated, in a Zope
>> environment.
>>
>
> Have you looked at nosetests? Nose
noffice; you could
try to get the OpenOffice.org developers guide and the SDK, and check
it (but it is not a little work)
Regards
Marco
> Thanks
>
> --greg
>
> --
> http://mail.python.org/mailman/listinfo/python-list
>
--
Marco Bizzarri
http://notenotturne.blogspot.com/
http://iliveinpisa.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
actively mantained and used in a big software project.
And, also, it should be quite easy to extend in order to have your
custom functions run via XML-RPC.
Regards
Marco
--
Marco Bizzarri
http://notenotturne.blogspot.com/
http://iliveinpisa.blogspot.com/
--
http://mail.python.org/mailman/listinfo
True
return False
Before devising my own solution for this kind of problem, I wonder if
there is a common solution for the problem. I'm looking for a
python2.3 solution.
Regards
Marco
--
Marco Bizzarri
http://notenotturne.blogspot.com/
http://iliveinpisa.blogspot.com/
--
http://mail.python.o
On Fri, Sep 12, 2008 at 4:09 PM, Diez B. Roggisch <[EMAIL PROTECTED]> wrote:
> Marco Bizzarri schrieb:
>>
>> Hi all.
>>
>> In many parts of my code I've the following schema of code:
>>
>>def isInUseByOutgoingRegistratio
> ... return True
> ...
>
> Diez
> --
> http://mail.python.org/mailman/listinfo/python-list
>
Thanks for the clarification, Diez! Indeed, I tried python2.3 and
python2.4, and of course not python2.5 ;)
I would like to make this available to the whole project. I suspect I
20061015 (prerelease) (Debian 4.1.1-16.1)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> def any(iterable): pass
...
>>> any(x for x in [1, 2, 3])
File "", line 1
any(x for x
On Fri, Sep 12, 2008 at 6:07 PM, Bruno Desthuilliers
<[EMAIL PROTECTED]> wrote:
> Marco Bizzarri a écrit :
> (snip)
>>
>> I'm afraid this have another problem for me...
>>
>>
>> [EMAIL PROTECTED]:/var/local/zope28/porting/Products/PAFlow$ pytho
able, like:
specification = FolderInUse(core)
if specification.true_for(folder):
...
Any thought about this?
Regards
Marco
--
Marco Bizzarri
http://notenotturne.blogspot.com/
http://iliveinpisa.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
On Sat, Sep 13, 2008 at 4:11 PM, Fredrik Lundh <[EMAIL PROTECTED]> wrote:
> Marco Bizzarri wrote:
>
>> class FolderInUse:
>
>>
>>
>>def true_for(self, archivefolder):
>>return any([instance.f
e the connection is
> made.
>
>
Maybe you can find this useful?
https://developer.skype.com/wiki/Skype4Py/examples/s4p_call_py
Regards
Marco
--
Marco Bizzarri
http://notenotturne.blogspot.com/
http://iliveinpisa.blogspot.com/
--
http://mail.python.org/mailman/listinfo/python-list
acc=0):
>if len(xs) == 0:
>acc
>else:
>suma(xs[1:], acc+xs[0])
You're just missing the "return" statements?
def suma(xs, acc=0):
if len(xs) == 0:
return acc
else:
return suma(xs
On Sun, Sep 14, 2008 at 10:08 AM, Marco Bizzarri
<[EMAIL PROTECTED]> wrote:
> On Sun, Sep 14, 2008 at 10:01 AM, cnb <[EMAIL PROTECTED]> wrote:
>> this recursive definition of sum thrumped me, is this some sort of
>> gotcha or am I just braindead today?
>> and yes
Piotr Sobolewski <[EMAIL PROTECTED]> writes:
> I would like to use a callable object as a method of a class. So, when I
> have such normal class:
>
> I want to change it to something like that:
>
> class add:
> def __call__(self, another_self):
> return another_self.version
On Thu, Sep 18, 2008 at 7:10 PM, Dieter Maurer <[EMAIL PROTECTED]> wrote:
> "Marco Bizzarri" <[EMAIL PROTECTED]> writes on Mon, 15 Sep 2008 20:26:27
> +0200:
>> On Mon, Sep 15, 2008 at 8:15 PM, Stefan Behnel <[EMAIL PROTECTED]> wrote:
>> > Mailing
;m curious how this can be done, does anyone know this?
>
> Almar
>
> --
> http://mail.python.org/mailman/listinfo/python-list
>
First result in "making a daemon in python with google":
http://mail.python.org/pipermail/python-list/2007-February/427692.html
(not tested)
Thank for your help.
I have try to follow your suggestion but I seem to fail.
Now my C-module (call it C_Core) code is:
***
/* create_list function */
int size=1000;
output=(double *) calloc(size, sizeof(double));
py_output=PyList_New(0);
for(i=0;
I know no one who was able to.
- I cannot write (*sigh*) the app in Python.
Any suggestions are very welcome!
Regards,
Marco (Forced to code in c++ again let me estimate the simplicity of
python)
--
http://mail.python.org/mailman/listinfo/python-list
er way. But the program below
> works and seems like it may be what you are asking for.
Perfect! That is precisely what I was looking for. I can easily adapt it
for my needs! Thanks a lot.
Regards,
Marco
--
http://mail.python.org/mailman/listinfo/python-list
Heck! I received 1 useless answer in comp.lang.c++ and here I get useful
links/hints and even a code-pattern! Great. Thank you all.
Sorry for posting a c++-problem here, but it was derived from my thinking
the Python way...
Cheers,
Marco
--
http://mail.python.org/mailman/listinfo/python
On 3/24/06, Sebastjan Trepca <[EMAIL PROTECTED]> wrote:
> m.select('myfolder')
Some attention is required here to retrieve subfolders.
Some imap servers like Cyrus and Courier uses "INBOX.subfolder" to
access subfolders.
--
Marco Carvalho (macs) | marcoacarvalho(
Could you please reveal your
value for text-string 'something'? Further I suggest
to replace the 'do something'-parts with 'print 42'.
Best wishes Marco
--
http://mail.python.org/mailman/listinfo/python-list
601 - 700 of 799 matches
Mail list logo