None is a valid value for io.TextIOBase.encoding, then why is it not a valid
value for bytes.encode()?
Regards,
Rocco
--
https://mail.python.org/mailman/listinfo/python-list
hi
I made the upgrade to python 2.4.3 from 2.4.2.
I want to take from google news some atom feeds with a funtion like
this
import urllib2
def takefeed(url):
request=urllib2.Request(url)
request.add_header('User-Agent', 'Mozilla/4.0 (compatible; MSIE 5.5;
Windows NT')
opener
This is the problem when I run the function
this is the result from 2.3.5
>>> print rss
http://purl.org/atom/ns#";>NFE/1.0Google
News Italiahttp://news.google.it/"/>Google News
ItaliaGoogle
Inc.[EMAIL PROTECTED]©2006
Google2006-05-28T19:09:13+00:00
Benedetto XVI: Wojtyla santo subito - LibertÃ
Also with ascii the function does not work.
--
http://mail.python.org/mailman/listinfo/python-list
Thanks Serge.
It's a gzip string.
So the code is
>>> import urllib2
>>> def takefeed(url):
request=urllib2.Request(url)
request.add_header('User-Agent', 'Mozilla/4.0 (compatible; MSIE
5.5;Windows NT')
opener = urllib2.build_opener()
data=opener.open(request).read()
here you'll find it in svn.
http://trac.defuze.org/browser/oss
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] wrote:
> On Fri, 30 Sep 2005 00:16:02 +1000
> Steven D'Aprano wrote:
>
>>Say you have written a class, with a private variable. I decide that I
>>need access to that variable, for reasons you never foresaw.
>
> What if the access to that variable was forbidden for reasons you ne
fraca7 wrote:
> Richie Hindle a écrit :
>
>> [Peter]
>>
>>> http://www.pick.ucam.org/~ptc24/yvfc.html
>>
>>
>>
>> [Jeff]
>>
>>> Yuma Valley Agricultural Center?
>>> Yaak Valley Forest Council?
>>
>>
>>
>> I went through the same process. My guess is "Yes, Very F'ing Clever."
>> Peter?
>>
>
> pri
Antoon Pardon wrote:
>>What if the class author removes a non-private variable or changes a
>>method's documented parameters in the next version of the class, because
>>he think it'll work better, or just because he can?
>
> Changing an interface is different from changing the implementation.
Paul Rubin wrote:
> I don't know of a single program that's actually relying on the
> non-enforcement. I've asked for examples but have only gotten
> theoretical ones. As far as I can tell, the feature is useless.
I'd like to turn the question around on you - can you come up with an
instance w
Reinhold Birkenfeld wrote:
> Hi,
>
> after Guido's pronouncement yesterday, in one of the next versions of Python
> there will be a conditional expression with the following syntax:
>
> X if C else Y
Any word on chaining?
That is, what would happen with the following constructs:
A if B else C
Roel Schroeven wrote:
> Peter Decker wrote:
>
>>On 10/3/05, Roel Schroeven <[EMAIL PROTECTED]> wrote:
>>
>>On lists like this, where everyone benefits by sharing information, it
>>seems pretty lame to hide behind purist arguments about Reply-To:
>>headers. The default behavior should be the one mo
Steve Holden wrote:
>> On Fri, 07 Oct 2005 00:33:43 -, Grant Edwards <[EMAIL PROTECTED]>
>> wrote:
>>> For example: In British English one uses a plural verb when the
>>> subject consists of more than one person. Sports teams,
>>> government departments, states, corporations etc. are gramma
Duncan Smith wrote:
> Steve Holden wrote:
>
>>There are special rules for the monarchs, who are expected to refer to
>>themselves in the first person plural.
>>
>
> Yes, although I'm not actually sure where the 'royal we' comes from;
I was under the (probably misinformed) impression that since
Laszlo Zsolt Nagy wrote:
> Laszlo Zsolt Nagy wrote:
>
>> I have a program with this code fragment:
>>
>>print len(data)
>>print data[:50]
>>raise SystemExit
>>
>> This prints:
>>
>> 20381
>> >
>> But if I change 50 to 51
>>
>>print len(data)
>>print data[:51]
>>raise System
James Stroud wrote:
> I propose that any time anyone suggests switching to Windows, the reasons for
> such should be explicitly described, and not left to interpretation.
I propose that any time anyone suggests switching to Linux ...
I propose that any time anyone suggests switching to Mac ...
I
Sori Schwimmer wrote:
> Hi,
>
> I think that would be useful to have an improved
> version of the "try" statement, as follows:
>
> try(retrys=0,timeout=0):
> # things to try
> except:
> # what to do if failed
>
> and having the following semantic:
>
> for i in range(retrys):
> try:
>
[EMAIL PROTECTED] wrote:
> So the first thing you do when you go to a web page is to google if
> they are going to redesign it?
I think the implication was "The first thing to do before *suggesting
that a redesign is nessasary* is to Google to see if such a redesign is
taking place."
--
http://
n always reply to the original
post, or reply to one, and just treat the topics from all of them.)
> 2) Rocco Morreti wrote:
First off, let me say that my message wasn't meant to scare you off - it
was constructive criticism, appraising you of what would be necessary if
you actually want
Alex Martelli wrote:
> The Eternal Squire <[EMAIL PROTECTED]> wrote:
>...
>
>>2) Consider what he really wants for a supervisor of software
>>engineers. Ideally such a person should be a software engineer with
>>at least 3 times the experience of the most junior member. Such a
>
>
> I li
[EMAIL PROTECTED] wrote:
> i m losing my motivation with python because there are sooo many
> modules, that i cant just learn them all,
As other's have said, don't bother.
If you ever need to use a module that you don't know, just go to
http://docs.python.org/lib/lib.html (easily accessable fr
Paul McGuire wrote:
> "Claire McLister" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
> We've been working with Google Maps, and have created a web service to
> map origins of emails to a group. As a trial, we've developed a map of
> emails to this group at:
>
> http://www.zees
[EMAIL PROTECTED] wrote:
> Rocco Moretti wrote:
>
>>It's also a testament to the limited value of physically locating people
>>by internet addresses - If you zoom in on the San Fransico bay area, and
>>click on the southern most bubble (south of San Jose), you'l
Pierre Barbier de Reuille wrote:
> Please, note that I am entirely open for every points on this proposal
> (which I do not dare yet to call PEP).
I still don't see why you can't just use strings. The only two issues I
see you might have with them are a) two identical strings might not be
identi
marduk wrote:
> On Tue, 2005-11-15 at 11:01 -0800, py wrote:
>
>>I have function which takes an argument. My code needs that argument
>>to be an iterable (something i can loop over)...so I dont care if its a
>>list, tuple, etc. So I need a way to make sure that the argument is an
>>iterable befo
Björn Lindström wrote:
> Steven D'Aprano <[EMAIL PROTECTED]> writes:
>
>
>>Why does the byte string "\x6f\x70\x65\x6e\x65\x64" have intrinsic
>>meaning when the int 0 doesn't? It certainly doesn't mean anything to
>>non-English speakers.
>>
>>If all you want is human readable byte strings, then j
Pierre Barbier de Reuille wrote:
> Rocco Moretti a écrit :
> [...]
>
>>
>>I did, but I still don't see why it is an argument against using
>>strings. The point you may not appreciate is that (C)Python already uses
>>strings to represent names, as an important
[EMAIL PROTECTED] wrote:
> There is problaly a really simple answer to this, but why does this
> function print the correct result but return "None":
>
> def add(x, y):
> if x == 0:
> print y
> return y
> else:
> x -= 1
> y += 1
> add(x, y)
>
> prin
tim wrote:
> ok, but if i do
>
> >>> n=66
> >>> m=hex(n)
> >>> m
> '0x42'
> >>> h=int(m,16)
> >>> h
> 66
> >>>
>
> I end up with 66 again, back where I started, a decimal, right?
> I want to end up with 0x42 as being a hex value, not a string, so i can
> pas it as an argument to a function
Steven D'Aprano wrote:
> On Fri, 25 Nov 2005 11:30:46 -0800, mojosam wrote:
>
>>I guess I don't care too much about how other people use it.
>
> Then probably the best licence to use is just to follow the lead of
> Python. For that sort of small program of limited value, I put something
> like th
mojosam wrote:
> I've been watching the flame war about licenses with some interest.
> There are many motivations for those who participate in this sector, so
> disagreements over licenses reflect those agendas.
One point that frequently gets ignored in licensing debates:
The value of a license i
Fredrik Lundh wrote:
> Rick Wotnaz wrote:
>
>
>>I'm sure Antoon wouldn't object if lists were to be allowed as
>>dictionary keys, which would eliminate the multiple castings for
>>that situation. I wouldn't, either.
>
> so what algorithm do you suggest for the new dictionary im-
> plementation?
Fredrik Lundh wrote:
> Rocco Moretti wrote:
>
>>>>I'm sure Antoon wouldn't object if lists were to be allowed as
>>>>dictionary keys, which would eliminate the multiple castings for
>>>>that situation. I wouldn't, either.
>>
josh wrote:
>
> hello,
>
> i am interested in doing an undergraduate major in computer science
> that mainly focuses on python as a programming language..
It's your life, so you can live it as you choose, but I think you're
missing the point of an undergraduate education if you focus too much o
A.M. Kuchling wrote:
> There's another struggle within the LibRef: is it a reference or a
> tutorial? Does it list methods in alphabetical order so you can look
> them up, or does it list them in a pedagogically useful order? I
> think it has to be a reference; if each section were to be a tutor
>>>One of my favourite examples of obfuscated English is this grammatically
>>>correct sentence:
>>>
>>>"Buffalo buffalo Buffalo buffalo buffalo buffalo Buffalo buffalo."
>
> The punctuation is important.
Reminds me of this old classic:
Insert punctuation & capitalization to make the following
Fredrik Lundh wrote:
> Rocco Moretti wrote:
>
>
>>Insert punctuation & capitalization to make the following a correct and
>>coherent (if not a little tourtured).
>>
>>fred where guido had had had had had had had had had had had a better
>>effect on the
[EMAIL PROTECTED] wrote:
thisisastring = "1"
thisisanint = 1
type(thisisastring)
>
>
>
type(thisisanint)
>
>
>
thisisastring = int(thisisastring)
thisisanint = str(thisisanint)
type(thisisastring)
>
>
>
type(thisisanint)
>
>
>>> print repr(thisisastring)
Roy Smith wrote:
In article <[EMAIL PROTECTED]>,
Quest Master <[EMAIL PROTECTED]> wrote:
So, my question is simply this: is there an implementation of another
scripting language into Python?
Python *is* a scripting language. Why not just let your users write
Python modules which you them impor
Bob Smith wrote:
Rocco Moretti wrote:
Python's also dangerous. Every time you do an "import module", you put
your system at risk of crashing, having the hard-drive wiped
Have you been drinking again?
No, not really. The "every time" comment should be viewed in the same
Orlando Vazquez wrote:
Jeff Shannon wrote:
Because you cannot make Python secure against a malicious (or
ignorant) user -- there's too much flexibility to be able to guard
against every possible way in which user-code could harm the system.
Parsing your own (limited) scripting language allows mu
Limin Fu wrote:
Dear all,
I am glad to announce in this mailing list that the lastest version
of a new scripting language has come out.
Since you chose to announce it in this mailing list/newsgroup, may I
suggest that a comparison with Python is in order?
Since it is a new scripting language, I'm
Andrea Griffini wrote:
> Indeed when talking about if learning "C" can hinder
> or help learning "C++" I remember thinking that to
> learn "C++" *superficially* learning "C" first is
> surely pointless or can even hinder.
> But to learn "C++" deeply (with all its quirks) I
> think that learning "C
scott wrote:
> hi people,
>
> can someone tell me, how to use a class like that* (or "simulate" more
> than 1 constructor) :
> #--
> class myPointClass:
> def __init__(self, x=0, y=0):
> self.x = x
> self.y = y
> def __init__(self, x=0, y=0, z=0):
> self.__init__(self, x, y)
>
Steven D'Aprano wrote:
> On Wed, 22 Jun 2005 12:34:21 -0500, Rocco Moretti wrote:
>
>
>>You could also turn __init__ into a dispatch fuction:
>>
>>#--
>>class myPointClass:
>> def __init__(self, *args):
>> if len(args) <= 2:
>
Tim Daneliuk wrote:
> Diez B. Roggisch wrote:
>
>> Tim Daneliuk wrote:
>>
>>> Casey Hawthorne wrote:
>>>
Do your planes fly over the earth's surface or through the ground?
>>>
>>>
>>>
>>>
>>> Why do you presume this has anything to do with airplanes?
>>>
>>
>> That was supposed to be a f
jean-marc wrote:
> PS If I knew that Python had a anniversary date, I'd also write to
> thanks our BDFL (and authors)! But no such luck, so I'm restaining
> myself!
> ;-))
From the FAQ:
> Here's a very brief summary of what started it all, written by Guido van
> Rossum:
>
>
>
> During the 19
David Bear wrote:
> I know there must be a better way to phrase this so google understands, but
> I don't know how.. So I'll ask people.
>
> Assume I have a list object called 'alist'.
>
> Is there an easy way to create a dictionary object with the members of
> 'alist' being the keys in the dicti
BORT wrote:
> I am toying with the idea of teaching my ten year old a little about
> programming. I started my search with something like "best FREE
> programming language for kids." After MUCH clicking and high-level
> scanning, I am looking at Python and Forth. Both have advocates that
> say
Rocco Moretti wrote:
> It's been quite some time since I've looked at Forth, and the reference
> material that I used then was probably outdated anyway.
Sorry, thought of one more thing Python has going for it vs. Forth -
reference material. Check the catalog of your local li
BORT wrote:
> Gentle folk of comp.lang.python, I heartily thank you all for your
> input. I think I'm taking the boys through the door marked "Logo." We
> may be back this way, though. We will likely need MORE in the nebulous
> future. I am impressed with the outpouring of support here!
Other
Paul Rubin wrote:
> Gregory Piñero <[EMAIL PROTECTED]> writes:
>
>>I'd like to see some database API's to the most common databases
>>included.
>
> Yes, certainly, this is a serious deficiency with Python.
Except that (please correct me if I'm wrong) there is somewhat of a
policy for not inclu
Roy Smith wrote:
> In article <[EMAIL PROTECTED]>,
> "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote:
>
>
>>You can even get closer, but it is NOT recommended
>>
>>class foostr(str):
>> def plural (self):
>>if self.value[-1] in "sz":
>>return self.value + "es"
>>els
Jan Danielsson wrote:
>However, when I look at the various Python modules/libraries, I see
> that there are several versions of them, for different versions of
> python. I've seen everything from "for python 1.5" up to "for python
> 2.4" with all versions in between. This scares me a little bi
Paul Rubin wrote:
> Rocco Moretti <[EMAIL PROTECTED]> writes:
>
>>Except that (please correct me if I'm wrong) there is somewhat of a
>>policy for not including interface code for third party programs which
>>are not part of the operating system. (I.e. the modu
Mike Meyer wrote:
> Peter Hansen <[EMAIL PROTECTED]> writes:
>
>
>>Mike Meyer wrote:
>>
>>>Yes. I once grabbed an old program that did assignments to None. But
>>>that's always been a bad idea.
>>
>>What was the use case!?
>
>
> Unpacking a tuple. Something like this:
>
> (foo, bar,
Joseph Garvin wrote:
> I'm curious -- what is everyone's favorite trick from a non-python
> language? And -- why isn't it in Python?
I'm not aware of a language that allows it, but recently I've found
myself wanting the ability to transparently replace objects. For
example, if you have a trans
François Pinard wrote:
> [Rocco Moretti]
>
>
>>foo, bar, _ = gen_tuple(stuff)
>
>
>>as '_' is already special cased (last result in interactive mode), and
>>is already used for "don't care" sematics in Prolog.
>
>
> `_
Jp Calderone wrote:
> On Fri, 01 Jul 2005 15:02:10 -0500, Rocco Moretti
> <[EMAIL PROTECTED]> wrote:
>
>>
>> I'm not aware of a language that allows it, but recently I've found
>> myself wanting the ability to transparently replace objects.
>
John Roth wrote:
> "Peter Maas" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
>
>> George Sakkis schrieb:
>>
>>> Given that the latest 2.x python will be 2.9
>>
>>
>> Why not 2.13 or 2.4711? Version strings are sequences of arbitrary
>> integers separated by dots and not decimal n
Raymond Hettinger wrote:
> [EMAIL PROTECTED] wrote:
>
>>The problem is that questions like 'What lang is fastest to develop
>>in?'
>>are hard to answer definitively.
>
>
> FWIW, Google's answer to that question is C++, Java, and Python. For
> any given problem, any of the three are acceptable.
Ert Ert wrote:
> Please help me i down loaded python nd itplays on MS-DOS mode and not on
> normal please help
Python itself is a command line program. "MS-DOS mode" *is* it's normal
mode.
As other's have mentioned, there are graphical front ends to Python
which you may be more comforatble wit
Robert Kern wrote:
> Jacob Page wrote:
>
>> Does this newsgroup find attachments acceptable?
>
> No. Please put files somewhere on the web and post a URL. This would be
> a good forum to informally announce and discuss your module.
To add to what Robert said, keep in mind this newsgroup is als
François Pinard wrote:
> I once worked with a PL/I compiler (on a big IBM mainframe), which was
> trying to be helpful by spitting pages of:
>
> Error SUCH AND SUCH, assuming that THIS AND THIS was meant.
>
> and continuing compilation nevertheless. It was a common joke to say
> that PL/I w
vch wrote:
> Here's an example from some book:
>
> def foo(n):
> s = [n]
> def bar(i):
> s[0] += i
> return s[0]
> return bar
>
> what I don't understand is how this example works, taking into account
> the LGB rule. I thought that s is not accessible from bar, but
Peter Decker wrote:
> On 7/12/05, Dark Cowherd <[EMAIL PROTECTED]> wrote:
>
>
>>Most lists when i hit reply it puts the list address back in the To
>>address and some lists allow you to configure this.
>>
>>But in this list reply sends the mail back as a private mail and there
>>seems to be no op
Joseph Garvin wrote:
> Anand wrote:
>
>> Hi
>>
>> Are there any tools that would help in porting code from
>> Pyton 2.3 to 2.4 ? I have gone through the whatsnew documents
>> and created a document comparing Python 2.4 to 2.3. But so far
>> has not been able to find any tool that will signal cod
rbt wrote:
> Say I have a list that has 3 letters in it:
>
> ['a', 'b', 'c']
>
> I want to print all the possible 4 digit combinations of those 3
> letters:
When I have occasion to do an iteration of iterations, I either use
recursion (already posted) or use an accumulator type loop:
items = [
[EMAIL PROTECTED] wrote:
> i want to get a small certificate or diploma in python.
> it should be online cuz i live in pakistan and wont have teast centers
> near me.
> it should be low cost as i am not rich.
> and hopefully it would be something like a a begginer certification cuz
> i am new to py
Leif K-Brooks wrote:
> rbt wrote:
>
>>IMO, most of the people who deride goto do so because they heard or read
>>where someone else did.
>
>
> 1 GOTO 17
> 2 mean,GOTO 5
> 3 couldGOTO 6
> 4 with GOTO 7
> 5 what GOTO 3
> 6 possibly GOTO 24
> 7 you!
Tim Golden wrote:
> Usually means you have a readline package installed:
Should the readline package be twiddled to change the "quit" string in
builtins to document the correct behavior?
--
http://mail.python.org/mailman/listinfo/python-list
> My "favorite" infinte loop with while is:
>
>i = 0
>while i < 20:
> do_process(i)
>
> Note the prominent *lack* of any change to i here?
>
> Oh, for:
>
> from i = 0
> invariant 0 <= i <= 20
> variant 21 - i
> until i > 19
> loop
> do_process(i)
>
[EMAIL PROTECTED] wrote:
> I am going to be doing a lot of work with large data sets stored in
> various netCDF files, and after checking out the alternatives, I would
> really like to go with SciPy. The problem is that SciPy offers no
> native netCDF support.
You may be having an issue because t
Scott Kilpatrick wrote:
> So wherever pycdf does a:
>
> from Numeric import *
>
> what is the equivalent for SciPy? i.e. where is the full Numeric module
> in SciPy?
Python packages are in a pretty flat hierarchy. There really isn't a
"SciPy Numeric" and a "pycdf Numeric" - Numeric, as an indep
projecktzero wrote:
> but..but...It's so much more fun to unleash your anger and fire back
> with all guns blazing fanning the flame war that most discussion groups
> degenerate into after a couple of responses. =)
>
> Actually, I had some self restraint yesterday. I wanted to write a
> ripping re
Asad Habib wrote:
> I agree with Mustafa. After all, we are a bunch of professionals and not
> vagabonds hired to take pot shots at one another.
Except that we're not all professionals. There are a large number of
hobbyists who use Python and this list.
At any rate, my suggestion was not to fors
Asad Habib wrote:
> Well, even if you are a hobbyist, that does not excuse you from being
> civil. After all, we are all humans beings that deserve to be treated with
> respect. Professional, hobbyist, vagabond, ogre, instigator, troll ...
> THERE IS NO EXCUSE ... please treat others with respect.
Adriano Varoli Piazza wrote:
> As far as I recall from Math Analysis, which I studied two months ago,
> you can't sort complex numbers. It makes no sense. The reason being
> (reading from my book), it's not possible to define an order that
> preserves the properties of arithmetical operations o
Christopher Subich wrote:
> Gregory Piñero wrote:
>
>> Hey guys, would someone mind giving me a quick rundown of how
>> references work in Python when passing arguments into functions? The
>> code below should highlight my specific confusion:
This URL is always tossed out:
http://starship.pytho
Gregory Piñero wrote:
> Ahh, so it's a mutable thing. That makes sense that I can't change a
> mutable object and thus can't affect it outside of the function.
If you meant "immutable" for the second mutable, you're right.
> Does
> that mean Python functions aren't always byref, but are someti
Dennis Lee Bieber wrote:
> On Tue, 09 Aug 2005 10:39:29 -0500, Rocco Moretti
> <[EMAIL PROTECTED]> declaimed the following in comp.lang.python:
>
>
>>Change it to "the object referenced by y is assigned to the name of x",
>>and you're closer to th
Christopher Subich wrote:
> Rocco Moretti wrote:
>
>> Variables in Python are names. They aren't the cubbyholes into which
>> you put values, they are sticky notes on the front of the cubby hole.
>
>
> +1 MOTW (Metaphor of the Week)
Thanks, but please note it&
Cameron Laird wrote:
> Andy Smith rails against "frameworks":
> http://an9.org/devdev/why_frameworks_suck?sxip-homesite=&checked=1
>
Slapdash Summary: Libraries good, frameworks bad - they are a
straightjackets and limit sharing.
Which lead me to the question - what's the dif
Simon Brunning wrote:
> On 8/15/05, Rocco Moretti <[EMAIL PROTECTED]> wrote:
>
>>Which lead me to the question - what's the difference between a library
>>and a framework?
>
>
> If you call its code, it's a library. If it calls yours, it's a fra
Simon Brunning wrote:
> On 8/15/05, Terry Hancock <[EMAIL PROTECTED]> wrote:
>
>>On Monday 15 August 2005 09:54 am, Simon Brunning wrote:
>>
>>>If you call its code, it's a library. If it calls yours, it's a framework.
>>
>>Such concision deserves applause. ;-)
>
>
> Thank you. ;-)
>
> As other
[EMAIL PROTECTED] wrote:
> I have a java program in a package called 'cmd'. This of course
> conflicts with the builtin python package of the same name. The thing
> is, I need to be able to import from both of these packages in the same
> script. I can import either one first, but any future attemp
Steve Holden wrote:
> Every page of the docs links to "About this document", which contains
> the following: """If you are able to provide suggested text, either to
> replace existing incorrect or unclear material, or additional text to
> supplement what's already available, we'd appreciate the
wen wrote:
> due to the work reason, i have to learn python since last month. i have
> spent 1 week on learning python tutorial and felt good. but i still don't
> understand most part of sourcecode of PYMOL(http://pymol.sourceforge.net/)
> as before.
Well, last time I checked, a good chunk of PyMo
Terry Hancock wrote:
> On Thursday 01 September 2005 07:28 am, Fuzzyman wrote:
>
>>What's the difference between this and ``isinstance`` ?
>
> I must confess that an "isa" operator sounds like it would
> have been slightly nicer syntax than the isinstance() built-in
> function. But not enough nic
Colin J. Williams wrote:
> Rocco Moretti wrote:
>
>> Terry Hancock wrote:
>>
>>> On Thursday 01 September 2005 07:28 am, Fuzzyman wrote:
>>>
>>>> What's the difference between this and ``isinstance`` ?
>>>
>>> I must confess t
[EMAIL PROTECTED] wrote:
> On Tue, 06 Sep 2005 12:19:21 +0200
> Torsten Bronger wrote:
>
>
>>"talin at acm dot org" <[EMAIL PROTECTED]> writes:
>>
>>>Anyway, here's an example, then, of how 'def' could be used:
>>>
>>>add = def( a, b ):
>>> return a + b
>>
>>I'm really not an expert in function
Rubinho wrote:
> I can't imagine one being much faster than the other except in the case
> of a huge list and mine's going to typically have less than 1000
> elements.
To add to what others said, I'd imagine that the technique that's going
to be fastest is going to depend not only on the lengt
Terry Reedy wrote:
> But that, I admit, would be an invalid conclusion. And that, I claim, is
> also invalid when 'iteration' and 'recursion' are reversed, no matter how
> often repeated in texts and articles. The difference is between the
> algorithms, not the differing syntactic expressions
Paul Dale wrote:
>
> Hi everyone,
>
> I'm writing an exception that will open a trouble ticket for certain
> events. Things like network failure. I thought I would like to have it
> only open a ticket if the exception is not caught. Is there a way to do
> this inside the Exception? As far as I
[EMAIL PROTECTED] wrote:
> So how do I define the function such as to discrimate wheter I call it by
> f(a1) or f(a2) ?
I don't want to sound rude, but I think you'll be better served by
telling us why you would want to do such a thing - ten to one someone
can suggest a better way to acomplish
Jeff Shannon wrote:
news.sydney.pipenetworks.com wrote:
Fredrik Lundh wrote:
a certain "princess bride" quote would fit here, I think.
I'm not really familiar with it, can you enlighten please.
(Taking a guess at which quote /F had in mind...)
Vezzini: "Inconceivable!"
Inigo:"You keep using th
For some reason I can't seem to make use of the google links. When I use
the above eg
http://groups.google.com/groups?frame=right&th=e562a771d1c827c9
I get a not found google page with url
http://groups-beta.google.com/groups?frame=right&th=e562a771d1c827c9
really wanted to spell file in a sickl
Shawn Milo wrote:
> How did you learn Python?
>
I was just wondering what the best books were for learning Python.
If you're open to options besides ink-on-tree, this is how I did it:
I read the official tutorial, trying stuff out in the interactive
interpreter when I didn't get something/had ques
John Roth wrote:
One of the comments on Artima asks a rather profound
question: static typing is an answer. What's the question?
(That's a paraphrase.)
The answer that everyone seems to give is that it
prevents errors and clarifies the program.
It might just be me, but I thought it was to simpl
John Roth wrote:
"Rocco Moretti" <[EMAIL PROTECTED]> wrote
>
Looking at C, it's doubtful error prevention and program clarification
was a serious objective in the static typing system. It's more
reasonable to conclude that C is statically typed because it allows
1 - 100 of 168 matches
Mail list logo