On 02/04/10 23:03, Julian wrote:
For those guys would be a poster quite cool which describes the most
popular and beloved python features.
That it is ego-orientated programming ;-)
http://mail.python.org/pipermail/python-announce-list/2009-April/007419.html
--
mph
--
http://mail.python.org/m
On 02/10/10 03:36, Tim Chase wrote:
Larry Hudson wrote:
But a minor rearrangement is simpler, and IMHO clearer:
if 'mystring' not in s:
print 'not found'
else:
print 'foundit'
print 'processing'
I've always vacillated on whether that would better be written as Larry
does, or as
if 'mystring'
On 02/10/10 10:53, Jean-Michel Pichavant wrote:
Quin wrote:
Well, now you know!
All I know is that you are using a python implementation that does not
support python 3. No wonder why your py3 code fails.
You knew you known, you know :-)
--
mph
--
http://mail.python.org/mailman/listinfo/
On 02/07/10 19:02, T wrote:
I have a script, which runs as a Windows service under the LocalSystem
account, that I wish to have execute some commands. Specifically, the
program will call plink.exe to create a reverse SSH tunnel. Right now
I'm using subprocess.Popen to do so. When I run it inte
On 02/05/10 19:53, Wanderer wrote:
Which is the more accepted way to compose method names nounVerb or
verbNoun?
For example voltageGet or getVoltage? getVoltage sounds more normal,
but voltageGet is more like voltage.Get. I seem to mix them and I
should probably pick one way and stick with it.
Well at least you are well written and more subtle than Xah Lee.
Though I find him also quite amusing, I do like a good flame-war every
now and again, and in that perspective I solute you.
--
mph
--
http://mail.python.org/mailman/listinfo/python-list
> floor(x) returns an integer
Why do you say that? Assuming you are talking about math.floor, it works
differently for me:
py> math.floor(10.0/3)
3.0
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
SIZE)
table[key(point)]
You could even use that key function as a key to a dictionary, if you
can't use lists for some reason.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
On 02/16/10 13:51, Alf P. Steinbach wrote:
- Alf (is this off-topic for the group?)
Strictly speaking yes, but I do find it interesting and there is nothing
wrong with ignoring posts you don't like to read.
--
mph
--
http://mail.python.org/mailman/listinfo/python-list
On 02/19/10 21:48, MattB wrote:
Hey all,
I've been working on a program that accesses my school's password
protected website and downloads directory names. I'm using mechanize.
Recently, the program has been unable to open the website, returning
the 'errno 61 connection refused' error. I presum
lallous wrote:
> Hello
>
> How can I do something similar to pure virtual functions in C++ ?
See, for example
http://code.activestate.com/recipes/266468/
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
sible to
do something like
if hasattr(c, 'cb') and not is_pure(c.cb):
c.cb("Hello", "World")
is_pure could, for example, look at a function attribute of the
callback. You'd write something like
@pure_virtual
def cb(self, param1, param2):
not_implemented
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
On 02/20/10 00:20, MattB wrote:
Also, based on Martin's comment, I just wanted to make you all aware
that I intend no misuse, but rather am just trying to learn, as I'm a
programming noob.
It wasn't my intention to imply that, rather the opposite, that if some
BOFH would see your action as m
lib32 libs and compiling Python with
> some magical switches.
The precise set of packages that you will need depends on the specific
Linux distribution. Check whether "gcc -m32" can build a hello-world
program. Then, set CC to "gcc -m32", and follow the build instructions
in P
o", "World")
>>
>> is_pure could, for example, look at a function attribute of the
>> callback. You'd write something like
>>
>> @pure_virtual
>> def cb(self, param1, param2):
>> not_implemented
>>
>> Regards,
>>
ded case, and 32s for the multi-threaded case when pinning
the Python process to a single CPU (using taskset(1)).
So it's 6% overhead for threading, and 25% penalty for multicore CPUs -
far from the 100% you seem to expect.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
Hi,
I know that this issue has been discussed before, but most of
the time using only one argument to eval().
Is it possible to use the following code, e.g. run as part of a
web application, to break in and if so, how?
import math
def myeval(untrustedinput):
return eval(untrustedinput, {"__
inux), what specific Python version had you been
using? (less important) what CPUs? If you can: what specific test suite?
A lot of science is about repeatability. Making a systematic study is
(IMO) over-valued - anecdotal reports are useful, too, as long as they
allow for repeatable experiments.
Regar
Actually I am still waiting for Java to be mainstream :-)
You could say it is popular, which it is without doubt but in my opinion
after C handed over it's pseudo de facto standard (mostly because a lot
of OS'es are written in it) nobody else has had enough momenta to reach
for that crown.
Ac
On 02/24/10 16:05, Peter Parker wrote:
Steve Holden wrote:
At 12.34 pm on November 13, 2011
At December 21, 2012 at 11:11 am (according to the Maya calendar)
On August 29, 1997, Java became mainstream. In a panic, Microsoft tried
to embrace, extend and exterminate the system, prompting Sun
On 02/25/10 10:26, simn_stv wrote:
what i am concerned about is scalability and
efficiency, well, as far as the 'core' is concerned.
would python be able to manage giving me a solid 'core' and will i be
able to use python provide any API i would like to implement?...
Python isn't the most eff
On 02/25/10 13:58, D'Arcy J.M. Cain wrote:
On Thu, 25 Feb 2010 02:26:18 -0800 (PST)
Our biggest problem was in
a network heavy element of the app and that was low level TCP/IP stuff
that rather than being Python's problem was something we used Python to
fix.
Out off interest, could you elabo
On 02/25/10 16:18, D'Arcy J.M. Cain wrote:
Very interesting, I had a similar kind of problem (a network balancer
that doesn't balance small tcp packages too well) and solved it by
wrapping the TCP package in UDP. UDP was treated differently, although
in overall switch and router manager it has
On 02/27/10 09:36, @ Rocteur CC wrote:
Hi a couple of fragmented things popped in my head reading your
question, non of them is very constructive though in what you actually
want, but here it goes anyway.
- Oneline through away script with re as a built in syntax, yup that
sounds like perl t
On 02/28/10 11:05, Stefan Behnel wrote:
Steven D'Aprano, 28.02.2010 09:48:
There ought to be some kind of competition for the least efficient
solution to programming problems
That wouldn't be very interesting. You could just write a code generator
that spits out tons of garbage code including
Gregory Ewing wrote:
> I posted a demonstration of this earlier in this thread.
As you wrote, your example does not work when using eval() like
in my original post with second and third parameter to eval():
>>> import math
>>> eval("[c for c in (0).__class__.__bases__[0].__subclasses__() if c.__n
On 03/02/10 19:44, MRAB wrote:
information, such as when it was completed, the status (OK or failed),
etc. You might want to wrap it in a class with locks (mutexes) to ensure
it's threadsafe.
What actually happens if multiple threads at the same time, write to a
shared dictionary (Not using the
On 03/05/10 19:21, wongjoek...@yahoo.com wrote:
Any specific reason why threading.Thread or multiprocessing is not
suitable to solve your problem?
--
mph
--
http://mail.python.org/mailman/listinfo/python-list
On 03/05/10 19:45, wongjoek...@yahoo.com wrote:
On 5 mrt, 20:40, "Martin P. Hellwig"
wrote:
On 03/05/10 19:21, wongjoek...@yahoo.com wrote:
Any specific reason why threading.Thread or multiprocessing is not
suitable to solve your problem?
--
mph
Because I got a memory leak in my
On 03/05/10 19:24, Pete Emerson wrote:
In a module, how do I create a conditional that will do something
based on whether or not another module has been loaded?
>
If someone is using foo module, I want to take advantage of its
features and use it in foobar, otherwise, I want to do something els
On 03/05/10 20:09, wongjoek...@yahoo.com wrote:
On 5 mrt, 21:02, "Martin P. Hellwig"
wrote:
On 03/05/10 19:45, wongjoek...@yahoo.com wrote:
On 5 mrt, 20:40, "Martin P. Hellwig"
wrote:
On 03/05/10 19:21, wongjoek...@yahoo.com wrote:
Any specific reason why
On 03/06/10 09:45, wongjoek...@yahoo.com wrote:
Yes, I saw this example also before. HOwever what I want is to call an
internal function which gets a reference of another internal function
as input and not calling an external program. Do you have any example
on that with subprocess module ?
Tha
On 03/07/10 21:08, News123 wrote:
Hi,
How can I kill my own process?
Some multithreaded programs, that I have are unable to stop when ctrl-C
is pressed.
Some can't be stopped with sys.exit()
So I'd just like to terminate my own program.
Examples of non killable (not killable with CTRL-C) pr
On 03/07/10 21:54, News123 wrote:
Hi Martin.
Hellwig wrote:
On 03/07/10 21:08, News123 wrote:
Hi,
How can I kill my own process?
Some multithreaded programs, that I have are unable to stop when ctrl-C
is pressed.
Some can't be stopped with sys.exit()
So I'd just like to termin
On 03/08/10 00:18, Paweł Banyś wrote:
Hello,
I have already read about Python and multiprocessing which allows using
many processors. The idea is to split a program into separate tasks and
run each of them on a separate processor. However I want to run a Python
program doing a single simple task
On 03/08/10 02:10, monkeys paw wrote:
I can xfer a file from a remote server using:
import urllib2 as u
x=u.urlopen('http://tycho.usno.navy.mil/cgi-bin/timer.pl')
for line in x:
print line
How can i write a file to the remote server?
I tried:
x = u.url.open('http://joemoney.net/somefile.txt
On 03/08/10 02:51, monkeys paw wrote:
On 3/7/2010 9:20 PM, Martin P. Hellwig wrote:
On 03/08/10 02:10, monkeys paw wrote:
I can xfer a file from a remote server using:
import urllib2 as u
x=u.urlopen('http://tycho.usno.navy.mil/cgi-bin/timer.pl')
for line in x:
print line
How can
On 03/08/10 17:06, Stephen Nelson-Smith wrote:
Hi,
I've written some (primitive) code to parse some apache logfies and
establish if apache has appended a session cookie to the end. We're
finding that some browsers don't and apache doesn't just append a "-"
- it just omits it.
It's working fine
> I can create ASCII strings containing byte values between 127 and 255.
No, you can't - or what you create wouldn't be an ASCII string, by
definition of ASCII.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
On 02/09/10 14:00, Phlip wrote:
Ah, now we get down to the root of the problem. Because Python is so
stuck on the "one best way to do it" mentality, language bigotry
prevented the Committee from picking from among several equally valid
but non-best options. And after 20 years of growth, Python s
Hi all,
Before I start reinventing a squared wheel, I have the following question:
Is there already a (standard) module that wraps around the various
os/sys information which checks if the platform + version is supported
for what I want to do with it.
For example I am currently looking at mak
> I don't know how to solve this problem and I am looking forward for
> help.
Try running "python setup.py install" directly, after downloading and
unpacking the package.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
On 03/10/10 21:52, J wrote:
I'm working on a project and thought I'd ask for a suggestion on how
to proceed (I've got my own ideas, but I wanted to see if I was on the
right track)
Well I can't speak with authority but I would go into similar lines,
especially since you want to call an externa
, use VS 2008. This comes with an AMD64
compiler. You technically don't need a 64-bit Windows, as it supports
cross-compilation (but you would need a 64-bit Windows to test it).
I personally build Python on a 32-bit machine, and move the MSI to a
64-bit machine for testing.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
On 03/11/10 22:08, Cal Who wrote:
Thanks, that helped a lot.
I'm having trouble knowing what to search for to find documenatation. For
example, is print a Python command, a numpy command or a java command?
I like to read the documentation even if the command is working for me.
Thanks again
On 03/11/10 01:37, Gabriel Genellina wrote:
En Wed, 10 Mar 2010 10:54:27 -0300, Martin P. Hellwig
escribió:
Before I start reinventing a squared wheel, I have the following
question:
Is there already a (standard) module that wraps around the various
os/sys information which checks if the
ll early adaptors.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
I'm still puzzled why I ship
the import libraries of all the pyd files as well - I can't see a reason
other than tradition]. Then, distutils should change to look it up there.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
are none. Various Python versions then
try different things; what they should do is to determine the terminal
encoding, and decode the bytes according to that one.
Regards,
Martin
(*) If a source encoding was given, the source is actually recoded to
UTF-8, parsed, and then re-encoded back into the o
Michael Rudolf wrote:
> Am 12.03.2010 21:56, schrieb Martin v. Loewis:
>> (*) If a source encoding was given, the source is actually recoded to
>> UTF-8, parsed, and then re-encoded back into the original encoding.
>
> Why is that?
Why is what? That string literals get reen
On 03/13/10 19:23, Steven D'Aprano wrote:
On Sat, 13 Mar 2010 12:52:39 -0600, John Bokma wrote:
For quite some time I thought that comp.lang.perl.misc was quite
unfriendly because of a certain attitude. comp.lang.python was quite a
refreshment for a while: very newbie friendly, less pissing con
there some queuing mechanism for client calls? Thanks in advance.
--erdinc
How I usually tackle stuff like this:
[mar...@aspire8930 /usr/home/martin]$ python
Python 2.6.4 (r264:75706, Jan 31 2010, 20:52:16)
[GCC 4.2.1 20070719 [FreeBSD]] on freebsd8
Type "help", "copyright
On 03/14/10 10:32, hackingKK wrote:
Instead of using the library directly,
isn't python-twisted a better choice?
Why?
--
mph
--
http://mail.python.org/mailman/listinfo/python-list
On 03/16/10 19:30, Hans Mulder wrote:
Ulrich Eckhardt wrote:
Chris Rebert wrote:
You're a bit behind the times.
If my calculations are right, that comic is over 2 years old.
import timetravel
I think you mean:
from __future__ import timetravel
-- HansM
Well according to Marty it is:
fr
mentation, therefore, the required synchronization primitives
needed will not function, see issue 3770.
Build mine from ports, with the following options (notice SEM & PTH):
[mar...@aspire8930 /usr/home/martin]$ cat /var/db/ports/python26/options
# This file is auto-generated by 'mak
On 03/18/10 16:17, drstoka wrote:
Hello,
I have to run a program as a child process inside my python program and
redirect it's output through a pipe to a parent program process.
So, I wrote this:
pipe = Popen('example_program', shell=True, bufsize=0, stdout=PIPE).stdout
and it works great.
No
i. If you find this too tedious to use,
please propose *base classes* that could become part of msilib, rather
than trying to create *subclasses* of the bdist_msi classes.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
really infrequently used in practice. So that you try to
write it strongly suggests that it is not actually text what you are
writing.
Also, your formulation suggests the same:
"Is there any way to write a value 253 to standard output?"
If you would really be writing text, you'd ask
"Is there any way to write 'ý' to standard output?"
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
On 03/23/10 23:38, Tim Chase wrote:
Just in case you're okay with a regexp solution, you can use
>>> s = "\t\tabc def "
>>> import re
>>> r = re.compile(r'^(\s*)(.*?)(\s*)$')
>>> m = re.match(s)
>>> m.groups()
('\t\t', 'abc def', ' ')
>>> leading, text, trailing = m.groups()
Ahhh regex,
> Is anyone else having trouble with the 2.6.5 Windows x86 installer?
Not me. Run
msiexec /i py...msi /l*v py.log
and inspect py.log for errors (post it to bugs.python.org if you can't
determine the cause of the problems).
Are you using SUBST by any chance?
Regards,
Martin
Hi all,
When I run the following snippet (drastically simplified, to just show
what I mean):
>>
import platform, sys
class One(object):
def __init__(self):
self.one = True
def change(self):
self.one = False
class Two(object):
def __init__(self):
self._inst
On 03/25/10 23:41, Christian Heimes wrote:
Martin P. Hellwig schrieb:
What I don't understand why in the second test, the last boolean is True
instead of (what I expect) False.
Could somebody enlighten me please as this has bitten me before and I am
confused by this behavior.
Hint: TEST
On 03/26/10 01:10, Rhodri James wrote:
Pretty much. In the sense that you're thinking of, every assignment
works that way, even the initial "TEST1 = One()". Assignment binds names
to objects, though you have to be aware that names can be such exotic
things as "t", "a[15]" or "TEST2.__instance_o
it's not only that Python
can't start it, but nobody can.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
On 03/31/10 22:37, J wrote:
Is there any way to tell PyDev in Eclipse to run a script that doesn't
end in .py? Even if I have to go and manually set something for each
file...
I've inherited (in a manner of speaking) a dev project that is done in
python2.6... I pulled the latest dev branch and
thon?
The common approach is to write
DATA="""\
yaml data here
"""
If you want to process the data in the same file, you can't really put
them at the end of the file - in fact, putting them at the beginning is
more common.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
On 04/03/10 14:38, Steve Holden wrote:
If you think you will persuade a crackpot to drop his lunacy by logical
argument you are clearly an optimist of the first water. But since I
like a challenge (and bearing in mind this is OT so I don't claim to be
an expert) you might try first of all persu
On 04/03/10 16:17, Steven D'Aprano wrote:
On Sat, 03 Apr 2010 15:43:41 +0100, Martin P. Hellwig wrote:
I am replying to this post not because I disagree but because it
postalogically fits the best (I am by no means an expert either).
IMHO, the crackpot in this regard is actually part
On 04/03/10 16:46, Patrick Maupin wrote:
On Apr 3, 9:43 am, "Martin P. Hellwig"> IMHO, the crackpot in this
regard is actually partially right,
multiplication does mean that the number must get bigger, however for
fractions you multiply four numbers, two numerators and two
deno
> Thanks for the confirmation Martin!
>
> Do you think, it the mentioned omission of the character names of some
> CJK ranges in unicodedata intended, or should it be reported to the
> tracker?
It's certainly a bug. So a bug report would be appreciated, but much
more so a
Am 22.11.2010 22:43, schrieb Martin Lundberg:
> Hi,
>
> I want to be able to let the user enter paths like this:
>
> apps/name/**/*.js
>
> and then find all the matching files in apps/name and all its
> subdirectories. However I found out that Python's glob f
to that?
There was indeed a kwalitee computation (cheesecake); it is unmaintained.
It is a urban myth that this had any impact on search results. It never did.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
locale (as you apparently do), but set it to
a locale that actually matches the encoding that you use.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
e
> problems. So I need something for which a filename is just a blob
> that shouldn't be monkeyed with.
In that case, you should use byte strings as file names, not
character strings.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
> The world does not revolve around Python. Unix filenames have been
> encoding-agnostic long before Python was around. If Python3 does not
> support this then it's a regression on Python's part.
Fortunately, Python 3 does support that.
Regards,
Martin
--
http://mail
ss a (Unicode) string to
open; instead, it will (as will Java) use your locale's encoding.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
ning either a list or False)
is not. If you return False from a function, the only other possible
result should be True.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
ly for single-byte encodings.
I'm not aware of a procedure that does that for multi-byte strings.
But perhaps you didn't mean "POSIX character class" in this literal
way.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
binding, supporting both
2.x and 3.x simultaneously will be straight-forward.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
uot;1".
In the end, in any project, there should be coding conventions,
and authors should follow them. What is legible is IMO much more
determined by convention than "intuition", at least to experienced
programmers (i.e. those that have been following the convention for
a long time).
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
I'd rather not fix it by adding all product names that Microsoft has
used for Windows. How about "Microsoft Windows (XP and later releases)"?
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
ou literal question: most certainly. At least you seem
to be considering it, so it's certainly being considered by somebody.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
conversions are correctly rounded.
The round() function is also now correctly rounded.
Not sure that this is correct English; I think it means that the
round() function is now correct.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
File "", line 1, in
TypeError: a float is required
But then, I'm not a native speaker (of English).
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
Am 30.12.2010 14:52, schrieb crow:
> Hi, I'm writing a test tool to simulate Web browser. Is there anyway
> to run JavaScript in python? Thanks in advance.
See PyV8: http://pypi.python.org/pypi/PyV8
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
b frameworks are available for
> Python3... I heard the Django is still not compatible with 3.x... Any
> idea guys?
You could try my port of Django to Py3k:
https://bitbucket.org/loewis/django-3k
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
should first determine what Python versions their
users want to see supported, and then look for solutions that cover
all these versions.
In the case of byte literals, the solution is fairly straight-forward,
and only moderately ugly.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
7;t helped
by 2to3, so compatibility within 2.x is more important to consider than
compatibility between 2.x and 3.x.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
Hi,
naively, I thought the following code:
#!/usr/bin/env python2.6
# -*- coding: utf-8 -*-
import codecs
d = { u'key': u'我爱中国人' }
if __name__ == "__main__":
with codecs.open("ilike.txt", "w", "utf-8") as f:
print >>f, d
would produce a file ilike.txt like this:
{u'key': u'我爱中国人'}
> What's the right way to get the strings in UTF-8?
This will work. I doubt you can get it much simpler
in 2.x; in 3.x, your code will work out of the box
(with proper syntactical adjustments).
import pprint, cStringIO
class UniPrinter(pprint.PrettyPrinter):
def format(self, obj, context, ma
On 2011-01-12 00:27, Martin v. Loewis wrote:
> This will work. I doubt you can get it much simpler
> in 2.x; in 3.x, your code will work out of the box
> (with proper syntactical adjustments).
Thanks, this works like a charm. I tried pprint before for this
task and failed. Now I
uared wheel
or am totally missing the point.
Any suggestions/comments are greatly appreciated,
Thanks in advanced,
Martin P. Hellwig
--
http://mail.python.org/mailman/listinfo/python-list
.
It might be a misconfiguration but, under mod_wsgi with apache it does.
Cheers,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
On 01/14/11 10:05, Kushal Kumaran wrote:
This might help though:
https://code.google.com/p/modwsgi/wiki/ProcessesAndThreading
It seems if you're not using 'daemon' mode, global data might be shared.
Yes I read that thoroughly before I started out implementing a solution.
But in my case I want
>> CGI is still used in some places today, hello?
>
> Yeah, James Cameron made a *ton* of money using it to make Avatar.
He used compacted graphite iron in Avatar? I didn't know that.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
On 01/17/11 19:39, rantingrick wrote:
Q: If you could replace Tkinter with any module/library (THAT IS NOT A
GUI OR IDE!!) what would you like to see fill its place?
Some systems, like FreeBSD have Tkinter and IDLE as a separate package
which is not installed by default. Purely because those
On 01/17/11 22:00, rantingrick wrote:
On Jan 17, 2:09 pm, "Martin P. Hellwig"
wrote:
fortunately it is not my call and I actually
quite like Tkinter.
Are you sure about that Martin? :)))
From: "Martin P. Hellwig"
Newsgroups: comp.lang.python
Subject: Re: GUIs - A Modes
y, and take the elements at indices 2k and 2k+1
together. Sorting would then only look at even indices, but any swapping
you do during the sorting would always swap two numbers with two other
numbers.
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
rror near unexpected token `('
> ./toto.pyc: line 2: `P7Mc@s dGHdS(tfooNs./
> toto.pys'
Works fine here:
martin@mira:/tmp$ cat >a.py
print "Hello, world"
martin@mira:/tmp$ python
Python 2.6.6 (r266:84292, Dec 26 2010, 22:31:48)
[GCC 4.4.5] on linux2
Ty
for a
module of the same name further down the path -- the new interpreter
will find the first .pyc file and complain about it, while the old
interpreter would ignore it and use the .py file further down.)
Regards,
Martin
--
http://mail.python.org/mailman/listinfo/python-list
3901 - 4000 of 4332 matches
Mail list logo