Op 2005-12-14, Grant Edwards schreef <[EMAIL PROTECTED]>:
> On 2005-12-14, Antoon Pardon <[EMAIL PROTECTED]> wrote:
>
> Well, as you might argue, I'm not tryng to effect a change in
> your behaviour, I'm simply trying to point out how it could be
> made more rational.
> [...]
Or re
Antoon Pardon wrote:
> Op 2005-12-14, Grant Edwards schreef <[EMAIL PROTECTED]>:
> > On 2005-12-14, Antoon Pardon <[EMAIL PROTECTED]> wrote:
> >
> > Well, as you might argue, I'm not tryng to effect a change in
> > your behaviour, I'm simply trying to point out how it could be
> > made
Op 2005-12-14, Mike Meyer schreef <[EMAIL PROTECTED]>:
> [EMAIL PROTECTED] writes:
>> Steve Holden wrote:
>>> >>It would be somewhat more self-documenting, but why not just use one
>>> >>name to indicate the state and another, only meaningful in certain
>>> >>states, to indicate the callback?
>>> >
Kenneth McDonald <[EMAIL PROTECTED]> wrote:
> I am going to demonstrate my complete lack of understanding as to
> going back and forth between
> character encodings, so I hope someone out there can shed some light
> on this. I have always
> depended on the kindness of strangers... :-)
>
> I'm
[EMAIL PROTECTED] wrote:
> Frank Millman wrote:
>
>>[EMAIL PROTECTED] wrote:
>>
>>>Sorry that I can't help you in any way but have a question myself. Is
>>>there an OS independent way to get this thing(regardless of how to
>>>format it) in Python ? I know this may not matter if all you want is
>>
[EMAIL PROTECTED] wrote:
> Frank Millman wrote:
> > [EMAIL PROTECTED] wrote:
> > > Sorry that I can't help you in any way but have a question myself. Is
> > > there an OS independent way to get this thing(regardless of how to
> > > format it) in Python ? I know this may not matter if all you want
Donn Cave wrote:
> Quoth Mike Meyer <[EMAIL PROTECTED]>:
> | Donn Cave <[EMAIL PROTECTED]> writes:
> ...
>
> The question is whether basically everyone needs to get there, or we
> can expect the masses to use the language _without understanding it_
> in this sense, without understanding the langua
Op 2005-12-14, Christopher Subich schreef <[EMAIL PROTECTED]>:
> Antoon Pardon wrote:
>> Suppose we would add type declarations in python.
>> So we could do things like
>>
>> int: a
>> object: b
>>
>> Some people seem to think that this would introduce static
>> typing, but the only effect th
Op 2005-12-14, Magnus Lycka schreef <[EMAIL PROTECTED]>:
> Christopher Subich wrote:
>> Doesn't work; duck typing is emphatically not subclass-typing. For this
>> system to still work and be as general as Python is now (without having
>> to make all variables 'object's), we'd need true interface
Steve Holden wrote:
> Why should you want to associate a MAC address with a socket? Each
> interface has an IP address, and it's that you should be using.
Say for example I want to find out the MAC if a particular interface in
python.
> It may well be possible to write Python code that will run o
[EMAIL PROTECTED] wrote:
> Steve Holden wrote:
>
>>Why should you want to associate a MAC address with a socket? Each
>>interface has an IP address, and it's that you should be using.
>
> Say for example I want to find out the MAC if a particular interface in
> python.
>
When you are asked "why
import os
print os.__file__
--
dsw
--
http://mail.python.org/mailman/listinfo/python-list
Hi Heiko,
Thanks so much for your help! I just tested it and it works like a
charm!
Test File 1
-- main.py
#!/usr/bin python
from lib import being
being.location()
Test File 2
-- being.py
#!/usr/bin/python
import os
def location():
print os.path.abspath(__file__)
res
Martin Christensen <[EMAIL PROTECTED]> writes:
>> "Tin" == Tin Gherdanarra <[EMAIL PROTECTED]> writes:
>
> Tin> Xah Lee wrote:
>>> recently i got a project that involves the use of php. In 2 days, i
>>> read almost the entirety of the php doc. Finding it a breeze
>>> because it is roughly base
Steve Holden wrote:
> [EMAIL PROTECTED] wrote:
> > Steve Holden wrote:
> >
> >>Why should you want to associate a MAC address with a socket? Each
> >>interface has an IP address, and it's that you should be using.
> >
> > Say for example I want to find out the MAC if a particular interface in
> >
[EMAIL PROTECTED] wrote:
> Steve Holden wrote:
>
>>[EMAIL PROTECTED] wrote:
>>
>>>Steve Holden wrote:
>>>
>>>
Why should you want to associate a MAC address with a socket? Each
interface has an IP address, and it's that you should be using.
>>>
>>>Say for example I want to find out the MAC
Steve Holden wrote:
> [EMAIL PROTECTED] wrote:
> > Steve Holden wrote:
> >
> >>[EMAIL PROTECTED] wrote:
> >>
> >>>Steve Holden wrote:
> >>>
> >>>
> Why should you want to associate a MAC address with a socket? Each
> interface has an IP address, and it's that you should be using.
> >>>
> >
Paul Rubin wrote:
>Laszlo Zsolt Nagy <[EMAIL PROTECTED]> writes:
>
>
>>But how can I transfer pure python objects otherwise? Pyro also uses
>>Pickle and it also transfers bytecode.
>>
>>
>Pyro in the past used pickle in an insecure way. I'd heard it had
>been fixed and I didn't realize it s
Steve Holden wrote:
> Peter Otten wrote:
>
>> Pelmen wrote:
>>
>>
>> class Test:
>>>
>>>
>>> def __getattr__(self, attr):
>>>print attr
>>>
>>> def foo(x):
>>>print x
>>>
>>>
>> t = Test()
>> print t
>>>
>>>
>>> __str__
>>>
>>> Traceback (most
Magnus Lycka wrote:
> To read the last x bytes of a file, you could do:
>
> >>> import os
> >>> x = 2000 # or whatever...
> >>> f=open('my_big_file')
> >>> l=os.fstat(f.fileno()).st_size
> >>> f.seek(l-x)
> >>> f.read()
You don't need fstat/st_size, you can ask seek to move to an offset
rela
BartlebyScrivener wrote:
> I'm curious about this part of the post. Any fluent Pythoners actually
> happy using Windows XP and, if so, do they use ipython as a kind of
> bash shell substitute? Other alternatives to compensate for the widely
> derided command line in windows?
I often use cygwin's b
Andrew MacIntyre ha escrito:
> Gabriel Genellina wrote:
> > File "C:\Apps\Python\Lib\threading.py", line 218, in wait
> > remaining = endtime - _time()
> > IOError: [Errno 2] No such file or directory
> >
> > The error appears to be inside the time module, and I can't explain the
> > IOError
Hi,
I hadn't seen any announcements regarding this, but there's a little
device recently released called a GP2X which is a small dual CPU
(2x200Mhz) device which runs Linux.
Anyway, I thought there might be someone in here interested to hear
that python AND pygame have both been ported to it alr
Hi,
Thanks to Peter, now I know how to control an *existing* Windows
service and how to run a *python script* as a Windows service. Although
these were really useful, my point was different.
I have developed a script that monitors a specified folder for changes
in the files or folders within it.
[EMAIL PROTECTED] wrote:
> Steve Holden wrote:
>
>>[EMAIL PROTECTED] wrote:
>>
>>>Steve Holden wrote:
>>>
>>>
[EMAIL PROTECTED] wrote:
>Steve Holden wrote:
>
>
>
>>Why should you want to associate a MAC address with a socket? Each
>>interface has an IP address
Steve Holden wrote:
> Nope, but I can make inferences, whose correctness you can choose to lie
> or tell the truth about. I was merely trying to make the point that your
> response failed to further anybody's understanding of anything. I'm not
> really bothered *why* you do what you do.
That is ni
Mondal wrote:
> Hi,
>
> Thanks to Peter, now I know how to control an *existing* Windows
> service and how to run a *python script* as a Windows service. Although
> these were really useful, my point was different.
>
> I have developed a script that monitors a specified folder for changes
> in the
[EMAIL PROTECTED] wrote:
> Steve Holden wrote:
>
>>Nope, but I can make inferences, whose correctness you can choose to lie
>>or tell the truth about. I was merely trying to make the point that your
>>response failed to further anybody's understanding of anything. I'm not
>>really bothered *why* y
Antoon Pardon wrote:
> Op 2005-12-14, Christopher Subich schreef
> > Doesn't work; duck typing is emphatically not subclass-typing.
>
> I don't see how that is relevant.
>
> > For this
> > system to still work and be as general as Python is now (without having
> > to make all variables 'object's),
Mondal wrote:
> Hi,
>
> Thanks to Peter, now I know how to control an *existing* Windows
> service and how to run a *python script* as a Windows service. Although
> these were really useful, my point was different.
>
> I have developed a script that monitors a specified folder for changes
> in th
Steve Holden wrote:
> I'm probably just not reading your responses carefully enough.
That is fine, misunderstanding happens all the time. And why I am
curious that there is no such thing in Python, it is because of this :
http://search.cpan.org/~lds/IO-Interface-0.98/Interface.pm
I am learning p
I must use text in Opengl, Python
This text is for architecture design then I need to use AutoCad fonts
(extension .shx).
I have two troubles:
I don't find a guide, a good program, something for use any kind of
fonts in PyOpengl. The nehe tutorial has some bugs in translation to
Python.
I need to
Mike Meyer wrote:
> [Not sure if this attribution is correct.]
> > Alex Martelli wrote:
> > Because of course if other languages have 1 or two frameworks, python
> > needs a dozen.
>
> People keep talking about Python's wealth of web frameworks as if it
> were a bad thing. I just don't see it. Just
Steve Holden wrote:
> Mondal wrote:
> > Hi,
> >
> > Thanks to Peter, now I know how to control an *existing* Windows
> > service and how to run a *python script* as a Windows service. Although
> > these were really useful, my point was different.
> >
> > I have developed a script that monitors a s
I reccomend David Mertz's text:
http://gnosis.cx/TPiP/
Despite name its more that just text processing, he uses
"modern" (ie, 20 - 30 years old) style of programming in examples,
often using library packages, especially parsing tools. Online version
is free, but you can pay him buy buying the p-bo
Steve Holden <[EMAIL PROTECTED]> writes:
> [EMAIL PROTECTED] wrote:
> > Steve Holden wrote:
> >
> >>Why should you want to associate a MAC address with a socket? Each
> >>interface has an IP address, and it's that you should be using.
> > Say for example I want to find out the MAC if a particular
As far as I know, Perl is known as "there are many ways to do
something" and Python is known as "there is only one way". Could you
please explain this? How is this possible and is it *really* a good
concept?
--
http://mail.python.org/mailman/listinfo/python-list
Michael Sparks wrote:
> I hadn't seen any announcements regarding this, but there's a little
> device recently released called a GP2X which is a small dual CPU
> (2x200Mhz) device which runs Linux.
>
> Anyway, I thought there might be someone in here interested to hear
> that python AND pygame hav
Op 2005-12-15, Ben Sizer schreef <[EMAIL PROTECTED]>:
>
> Antoon Pardon wrote:
>> Op 2005-12-14, Christopher Subich schreef
>> > Doesn't work; duck typing is emphatically not subclass-typing.
>>
>> I don't see how that is relevant.
>>
>> > For this
>> > system to still work and be as general as Pyt
Tolga wrote:
> As far as I know, Perl is known as "there are many ways to do
> something" and Python is known as "there is only one way". Could you
> please explain this? How is this possible and is it *really* a good
> concept?
if you 'import this', you get a bit of Python Zen... from which I ha
[EMAIL PROTECTED] wrote:
> Tolga wrote:
> > As far as I know, Perl is known as "there are many ways to do
> > something" and Python is known as "there is only one way". Could you
> > please explain this? How is this possible and is it *really* a good
> > concept?
>
> if you 'import this', you get
Tolga wrote:
> As far as I know, Perl is known as "there are many ways to do
> something" and Python is known as "there is only one way". Could you
> please explain this? How is this possible and is it *really* a good
> concept?
>
Perl's credo is actually "There's more than one way to do it", ofte
On 15 Dec 2005 04:32:39 -0800, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
> [EMAIL PROTECTED] wrote:
> > Tolga wrote:
> > > As far as I know, Perl is known as "there are many ways to do
> > > something" and Python is known as "there is only one way". Could you
> > > please explain this? How is
At Thursday 15 December 2005 00:33, tetri wrote:
> alguém recomenda algum material disponível na internet para iniciar
> os estudos em python?
> outra coisa, peço que brasileiros (ou ao menos aqueles que me
> entendem) se identifiquem, assim podemos começar discussões em
> português mesmo, o que ac
Chris Mellon wrote:
> On 15 Dec 2005 04:32:39 -0800, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> >
> > [EMAIL PROTECTED] wrote:
> > > Tolga wrote:
> > > > As far as I know, Perl is known as "there are many ways to do
> > > > something" and Python is known as "there is only one way". Could you
>
The only self aware Python scripts that I'm aware are the timbot and
the effbot. Their sources are available from the PSU website at
--
http://mail.python.org/mailman/listinfo/python-list
Antoon Pardon wrote:
> Op 2005-12-15, Ben Sizer schreef <[EMAIL PROTECTED]>:
> So? I answered a question. That my answer is not usefull for
> a specific purpose is very well prosible but is AFAIC irrelevant.
The point being made was that your declarations such as these:
int: a
object: b
wo
On 15 Dec 2005 05:08:02 -0800, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
> Chris Mellon wrote:
> > On 15 Dec 2005 04:32:39 -0800, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> > >
> > > [EMAIL PROTECTED] wrote:
> > > > Tolga wrote:
> > > > > As far as I know, Perl is known as "there are many
[EMAIL PROTECTED] wrote:
[...]
> It is perfectly ok to define coding policy within an organisation, for
> a project that have more than one developer and things like that. But
> if the language allows more than one way to do it, people would try if
> that is what they want and they can.
>
> I woul
On 15 Dec 2005 05:08:02 -0800
[EMAIL PROTECTED] wrote:
> I would say that if "only one way to do it" is the intend,
> make it into the language and any other way is simply
> error. Say if ternary operator is not the "preferred way",
> don't have it in the language. If someone find a way to
> work a
Chris Mellon wrote:
>You seem very, very interested in portraying anyone who
> wants to encourage good style and readability as a language Nazi. I
> don't appreciate that. You'll notice that I haven't taken the easy way
> out and told you to go away and play with Perl, right?
Noop. My stand is tha
QOTW: "If I feel the need for languages that enforce my design
decisions, I know where to find them." - Mike Meyer
"There's ... unavoidable complexity involved in managing a software
distribution composed of third party software packages. At the very
least, you've got the original sources and t
>> Now how can I go about deleting that record when it's too old?
>>
> (untested)
>
> try
>
> del db[ipAddress]
Yep, that did it. Thanks!
--
http://mail.python.org/mailman/listinfo/python-list
Hello,
Is there a simple flag to set to allow overlapping matches
for the findall() regular expression method? In other words,
if a string contains five occurrences of the string pattern
"cat", calling findall on the string returns a list
containing five "cat" strings. Is it possible for findall()
Steve Holden wrote:
> This would have the unfortunate side effect of only allowing changes to
> Python that allowed users to do things which are currently impossible.
>
> Since Python is Turing-complete, this would effectively inhibit all
> further changes to the language.
I don't quote understand
Aloha,
richard wrote:
> Dennis Benzinger wrote:
>>Does anybody know of a SVG rendering library for Python?
> Google "python svg"
... to find what?
Whishing a happy day
LOBI
--
http://mail.python.org/mailman/listinfo/python-list
Terry Hancock wrote:
> But that is precisely what it does mean -- Python's language
> design tries to be "reasonably minimal": there's usually one
> fairly easy way to do a task. Unintentionally, there may
> well be a half-dozen really hard ways to do it. The point of
> telling this to the potenti
On 2005-12-15, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
Why should you want to associate a MAC address with a socket? Each
interface has an IP address, and it's that you should be using.
>>>
>>> Say for example I want to find out the MAC if a particular
>>> interface in python.
>>
>> W
On 2005-12-15, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>>Why should you want to associate a MAC address with a socket? Each
>>interface has an IP address, and it's that you should be using.
>
>Say for example I want to find out the MAC if a particular interface in
>python.
Ben Sizer wrote:
> Mike Meyer wrote:
> > [Not sure if this attribution is correct.]
> > > Alex Martelli wrote:
> > > Because of course if other languages have 1 or two frameworks, python
> > > needs a dozen.
> >
woops, that attribution is absolutely *wrong*, DH said that, sorry Alex
--
http://m
Grant Edwards wrote:
> On 2005-12-15, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
> Why should you want to associate a MAC address with a socket? Each
> interface has an IP address, and it's that you should be using.
> >>>
> >>> Say for example I want to find out the MAC if a particular
Grant Edwards wrote:
> > you can read my temper from what I write ?
>
> If not, then you should be more careful what you write.
>
such as ?
--
http://mail.python.org/mailman/listinfo/python-list
On 2005-12-15, Antoon Pardon <[EMAIL PROTECTED]> wrote:
> Or return NaN instead of raising exception for numeric
> functions ?
Because usually (in my applications anyway) NaN is a perfectly
valid value and not an "exception" case that needs to be
handled.
>>>
>>> I don'
Ben Sizer wrote:
> Mike Meyer wrote:
> > [Not sure if this attribution is correct.]
> > > Alex Martelli wrote:
> > > Because of course if other languages have 1 or two frameworks, python
> > > needs a dozen.
> >
> > People keep talking about Python's wealth of web frameworks as if it
> > were a ba
Steve Holden wrote:
> Would you, say, remove "for" loops because they could be written as
> "while" loops. Don't forget the word "obvious" that appears in that
> catchphrase ...
Interestingly - and somewhat related to this - the other day I was
looking for a do..while or do..until loop in the Pyt
Op 2005-12-15, Ben Sizer schreef <[EMAIL PROTECTED]>:
>
> Antoon Pardon wrote:
>> Op 2005-12-15, Ben Sizer schreef <[EMAIL PROTECTED]>:
>
>> So? I answered a question. That my answer is not usefull for
>> a specific purpose is very well prosible but is AFAIC irrelevant.
>
> The point being made was
Chris Mellon wrote:
[...]
> (Am I dating myself? ...)
>
Do we need to know about your love life here? Are you hermaphroditic? If
not the relationship will never go anywhere.
regards
Steve
--
Steve Holden +44 150 684 7255 +1 800 494 3119
Holden Web LLC www.holdenweb
[EMAIL PROTECTED] wrote:
> Steve Holden wrote:
>
>>This would have the unfortunate side effect of only allowing changes to
>>Python that allowed users to do things which are currently impossible.
>>
>>Since Python is Turing-complete, this would effectively inhibit all
>>further changes to the lang
Can anyone recommend some code for creating drop-down menus in tkinter?
To be absolutely clear, here's an example of a drop-down:
http://www.google.co.uk/preferences?hl=en
(see the language selection widget)
I've found the odd bit of code here and there, such as:
http://infohost.nmt.edu/tcc/cgi/p
Yes, a shared preferred way.
And the same is true of many... Think Haskell, OCaml, Lua, Ruby, Lisp,
Smalltalk, Java, C... They all have qualities of some sort, that appeal
to some of us. Not all the same, nor to all of us. It's really a
question of perspective.
In this Python community, one shared
Tolga wrote:
> As far as I know, Perl is known as "there are many ways to do
> something" and Python is known as "there is only one way". Could you
> please explain this? How is this possible and is it *really* a good
> concept?
Yes it is a good concept because you can concentrate on Strategy rat
Kenneth McDonald wrote:
> At the moment I'm doing most of my stuff on a Mac, but I've been
> considering also getting
> a Windows laptop. One of the reasons is that I've found it very
> difficult to get certain
> Python related things running on the Mac; for example, if one wants to
> use the most
Steve Holden wrote:
> This would have the unfortunate side effect of only allowing changes to
> Python that allowed users to do things which are currently impossible.
>
> Since Python is Turing-complete, this would effectively inhibit all
> further changes to the language.
I don't quote understand
Steve Holden wrote:
> It says that Python is already adequately expressive to allow it to
> solve all solvable problems: more briefly, "Python can already do
> everything". Hence there is no need to change the language.
>
> Of course I use this as a /reductio ad absurdum/ to try to show you the
>
Ben Sizer wrote:
> Steve Holden wrote:
>
>
>>Would you, say, remove "for" loops because they could be written as
>>"while" loops. Don't forget the word "obvious" that appears in that
>>catchphrase ...
>
>
> Interestingly - and somewhat related to this - the other day I was
> looking for a do..w
In article <[EMAIL PROTECTED]>,
Alex Martelli <[EMAIL PROTECTED]> wrote:
>
>Right, you can get good genericity with Haskell's typeclasses (I've
>posted about that often in the past, and desperately and so far
>unsuccessfully tried to convince Guido to use something close to
>typeclasses rather than
[EMAIL PROTECTED] wrote:
>
Would you, say, remove "for" loops because they could be written as
"while" loops. Don't forget the word "obvious" that appears in that
catchphrase ...
>>> If every "for" usage can be done with "while" and that "while" is the
>>> prefe
Alex Hunsley wrote:
> Can anyone recommend some code for creating drop-down menus in tkinter?
> To be absolutely clear, here's an example of a drop-down:
>
> http://www.google.co.uk/preferences?hl=en
> (see the language selection widget)
>
> I've found the odd bit of code here and there, such as:
In article <[EMAIL PROTECTED]>,
Steve Holden <[EMAIL PROTECTED]> wrote:
>
>(Part of) Python's credo (which you can read in context by typing
>
> import this
>
>at an interactive command prompt) is "There should be one (and
>preferably only one) way to do it".
Actually, I've gotten used to do
[Steve]
> Since Python is Turing-complete
Is there some equivalent of Godwin's Law that we can invoke at this
point? 8-)
--
Richie Hindle
[EMAIL PROTECTED]
--
http://mail.python.org/mailman/listinfo/python-list
Aahz wrote:
> In article <[EMAIL PROTECTED]>,
> Steve Holden <[EMAIL PROTECTED]> wrote:
>> (Part of) Python's credo (which you can read in context by typing
>>
>> import this
>>
>> at an interactive command prompt) is "There should be one (and
>> preferably only one) way to do it".
>
> Actua
Mike,
I nosed around after reading the posts herein. Have you heard of monad,
the new Windows Command Shell in beta?
http://www.microsoft.com/downloads/details.aspx?FamilyID=2ac59b30-5a44-4782-b0b7-79fe2efd1280&DisplayLang=en
http://en.wikipedia.org/wiki/MSH_(shell)
Or a better article:
http:/
Carl J. Van Arsdall wrote:
> Although, obvious to whom is a good question. If you don't know the
> language very little will be obvious to you, however one who is familiar
> with python (rtfm) would know which cases should obviously use "while"
> and which cases should obviously use "for"
>
So fa
Aahz wrote:
> In article <[EMAIL PROTECTED]>,
> Steve Holden <[EMAIL PROTECTED]> wrote:
>
>>(Part of) Python's credo (which you can read in context by typing
>>
>>import this
>>
>>at an interactive command prompt) is "There should be one (and
>>preferably only one) way to do it".
>
>
> Act
Steve Holden wrote:
> This would have the unfortunate side effect of only allowing changes to
> Python that allowed users to do things which are currently impossible.
>
> Since Python is Turing-complete, this would effectively inhibit all
> further changes to the language.
I don't quite understand
Re: package installers:
I misspoke. The address for them is http://pythonmac.org/packages/
--
Cheers,
Kevin Walzer, PhD
WordTech Software - "Tame the Terminal"
http://www.wordtech-software.com
sw at wordtech-software.com
--
http://mail.python.org/mailman/listinfo/python-list
Hello,
How do I find out what modules have been included in my python install?
I am having issues with crypt functions not working on ubuntu or redhat
but they work on Slackware.
Any assistance would be great.
Regards,
Johhny.
--
http://mail.python.org/mailman/listinfo/python-list
On 12/15/05, Steve Holden <[EMAIL PROTECTED]> wrote:
> Aahz wrote:
> > python -c 'import this'
>
> Faster:
>
>python -m this
So, there's two ways to do it. ;-)
--
Cheers,
Simon B,
[EMAIL PROTECTED],
http://www.brunningonline.net/simon/blog/
--
http://mail.python.org/mailman/listinfo/pyth
[EMAIL PROTECTED] wrote:
> Chris Mellon wrote:
>
>>Any time you want to write something in any way other than the obvious
>>way, ask yourself why? Is it more obvious *to you*, which is a good
>>reason as long as you're only writing code for yourself? Or is it just
>>to be different, or because you
Hallöchen!
Sorry for the late response, but the subject didn't catch my
attention ...
Mike Meyer <[EMAIL PROTECTED]> writes:
> [EMAIL PROTECTED] writes:
>
>> In float mode, the instrument returns a sequence of bits that are
>> exactly the ieee754 number in the case of floats, or just the
>> flag
Kenneth McDonald wrote:
> At the moment I'm doing most of my stuff on a Mac, but I've been
> considering also getting
> a Windows laptop. One of the reasons is that I've found it very
> difficult to get certain
> Python related things running on the Mac; for example, if one wants
> to use the most
[EMAIL PROTECTED] wrote:
> C-programmer learning python :
>
> Hi, where is condition ? true : false
>
> someone prefer the if/else statement type:
>
> Can't you see that the following is much more readable, stupid(well not
> the exact word but tone in such a way like words of messy or elegant
> et
Well, that kinda depends on what you want the MAC Address of. Personally (on
Unix systems) I
simply read from a popen('ifconfig') and use a regular expression to parse out
the mac address.
Works perfectly.
Just my 2¢,
Michael
--
http://mail.python.org/mailman/listinfo/python-list
On Wed, 14 Dec 2005 21:16:23 +0100 in comp.lang.python, Lawrence
Oluyede <[EMAIL PROTECTED]> wrote:
>Il 2005-12-14, Andy Leszczynski <[EMAIL PROTECTED]> ha scritto:
>> How can do elegantly in Python:
>>
>> if condition:
>> a=1
>> else:
>> a=2
>>
>> like in C:
>>
>> a=condition?1:2
>>
>
>Th
Il 2005-12-15, [EMAIL PROTECTED] <[EMAIL PROTECTED]> ha scritto:
> How do I find out what modules have been included in my python install?
Look in site-packages directory
> I am having issues with crypt functions not working on ubuntu or redhat
> but they work on Slackware.
Crypt functions? Are
<[EMAIL PROTECTED]> wrote:
...
> > [protocol adaptation]); it's the state of _templates_ in Haskell,
> > specifically, which I was rather dubious about (it may be that I just
> > haven't dug into them deep enough yet, but they do seem not a little
> > "convoluted" to me, so far).
> >
> Yup, the
gene tani <[EMAIL PROTECTED]> wrote:
> Ben Sizer wrote:
> > Mike Meyer wrote:
> > > [Not sure if this attribution is correct.]
> > > > Alex Martelli wrote:
> > > > Because of course if other languages have 1 or two frameworks, python
> > > > needs a dozen.
>
> woops, that attribution is absolutel
Aahz <[EMAIL PROTECTED]> wrote:
...
> Hrm. I don't recall anything about typeclasses, so my suspicion is that
> you were writing something lengthy and above my head. Can you write
> something reasonably short about it? (I'm asking partly for your
> benefit, because if it makes sense to me, th
Peter Otten wrote:
>
> def add_freqs3(freq1, freq2):
> total = dict(freq1)
> for key, value in freq2.iteritems():
> try:
> total[key] += value
> except KeyError:
> total[key] = value
> return total
>
Untested, but replacing the try/except pair
Christopher Subich wrote:
> Peter Otten wrote:
> >
> > def add_freqs3(freq1, freq2):
> > total = dict(freq1)
> > for key, value in freq2.iteritems():
> > try:
> > total[key] += value
> > except KeyError:
> > total[key] = value
> > return total
>
1 - 100 of 269 matches
Mail list logo