On Jan 27, 3:06 pm, Peter Pei [EMAIL PROTECTED] wrote:
I probably should mention that what I want is to make all parts of the
string aligned, and look like table. I am not looking for other ways to make
it table-alike, but only interested in making % work with unicode -counting
characters not
On Jan 27, 8:45 am, Steven D'Aprano [EMAIL PROTECTED]
cybersource.com.au wrote:
I have a problem which I think could be solved by using a dict as a
namespace, in a similar way that exec and eval do.
When using the timeit module, it is very inconvenient to have to define
functions as strings.
On Jan 27, 4:02 am, Robb Lane (SL name) [EMAIL PROTECTED] wrote:
I have written a script which:
- opens a file
- does what it needs to do, periodically writing to the file... for a
few hours
- then closes the file when it's done
So my question is:
Would it be better to 'open' and 'close' my
Ever heard the word PLONK?
Peter Pei harshly top-posted:
You didn't understand my question, but thanks any way.
Yes, it is true that %s already support unicode, and I did not
contradict that. But it counts the number of bytes instead of
characters, and makes things like %-20s out of
On Fri, 25 Jan 2008 17:36:06 -0800 (PST), ajaksu [EMAIL PROTECTED]
wrote:
On Jan 25, 11:10 pm, [EMAIL PROTECTED] wrote:
Once a python py file is compiled into a pyc file, I can disassemble
it into assembler. Assembler is nothing but codes, which are
combinations of 1's and 0's. You can't read
On Fri, 25 Jan 2008 17:44:07 -0800 (PST), ajaksu [EMAIL PROTECTED]
wrote:
On Jan 25, 11:36 pm, ajaksu [EMAIL PROTECTED] wrote:
On Jan 25, 11:10 pm, [EMAIL PROTECTED] wrote:
[...]
Gaah, is this what's going on?
[EMAIL PROTECTED]:~$ cat error.txt
This is not assembler...
[EMAIL PROTECTED]:~$
On Jan 27, 9:58 am, [EMAIL PROTECTED] wrote:
On Fri, 25 Jan 2008 17:44:07 -0800 (PST), ajaksu [EMAIL PROTECTED]
wrote:
On Jan 25, 11:36 pm, ajaksu [EMAIL PROTECTED] wrote:
On Jan 25, 11:10 pm, [EMAIL PROTECTED] wrote:
[...]
Gaah, is this what's going on?
[EMAIL PROTECTED]:~$ cat
On Sun, 27 Jan 2008 08:58:01 +, over wrote:
On Fri, 25 Jan 2008 17:44:07 -0800 (PST), ajaksu [EMAIL PROTECTED]
wrote:
On Jan 25, 11:36 pm, ajaksu [EMAIL PROTECTED] wrote:
On Jan 25, 11:10 pm, [EMAIL PROTECTED] wrote:
[...]
Gaah, is this what's going on?
[EMAIL PROTECTED]:~$ cat
Gabriel Genellina wrote:
use the Windows sort command. It has been
there since MS-DOS ages, there is no need to download and install other
packages, and the documentation at
http://technet.microsoft.com/en-us/library/bb491004.aspx says:
Limits on file size:
The sort command has no limit
On Sun, 27 Jan 2008 05:32:40 +, Peter Pei wrote:
You didn't understand my question, but thanks any way.
Yes, it is true that %s already support unicode, and I did not contradict
that. But it counts the number of bytes instead of characters, and makes
things like %-20s out of
On 1月24日, 下午5时51分, John Machin [EMAIL PROTECTED] wrote:
On Jan 24, 2:49 pm, glacier [EMAIL PROTECTED] wrote:
I use chinese charactors as an example here.
s1='你好吗'
repr(s1)
'\\xc4\\xe3\\xba\\xc3\\xc2\\xf0'
b1=s1.decode('GBK')
My first question is : what strategy does 'decode' use
On 2008-01-27, Stefan Behnel [EMAIL PROTECTED] wrote:
Gabriel Genellina wrote:
use the Windows sort command. It has been
there since MS-DOS ages, there is no need to download and install other
packages, and the documentation at
http://technet.microsoft.com/en-us/library/bb491004.aspx says:
On 1月24日, 下午3时29分, Gabriel Genellina [EMAIL PROTECTED] wrote:
En Thu, 24 Jan 2008 04:52:22 -0200, glacier [EMAIL PROTECTED] escribió:
According to your reply, what will happen if I try to decode a long
string seperately.
I mean:
##
a='你好吗'*10
On 1月24日, 下午4时44分, Marc 'BlackJack' Rintsch [EMAIL PROTECTED] wrote:
On Wed, 23 Jan 2008 19:49:01 -0800, glacier wrote:
My second question is: is there any one who has tested very long mbcs
decode? I tried to decode a long(20+MB) xml yesterday, which turns out
to be very strange and cause
bearophile:
That version is easy to translate to other languages and you can
probably find that Psyco makes it much faster still.
That operation is quite common, so it deserves a bit more work:
http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/543271
(I can show you the D/C code if you
On Sun, 27 Jan 2008 10:00:45 +, Grant Edwards wrote:
On 2008-01-27, Stefan Behnel [EMAIL PROTECTED] wrote:
Gabriel Genellina wrote:
use the Windows sort command. It has been
there since MS-DOS ages, there is no need to download and install other
packages, and the documentation at
[EMAIL PROTECTED] wrote:
hehe...which part am I kidding about? The explanation was for
someone who thought python scripts were translated directly by the
processor.
Who might this have been? Surely not Tim.
I have already disassembled a pyc file as a binary file.
Have you? How's it look?
On Sun, 27 Jan 2008 02:18:48 -0800, glacier wrote:
Yepp. I feed SAX with the unicode string since SAX didn't support my
encoding system(GBK).
If the `decode()` method supports it, IMHO SAX should too.
Is there any way to solve this better?
I mean if I shouldn't convert the GBK string to
[EMAIL PROTECTED] writes:
The final sum: the Psyco version is almost 40 times faster than the
Python version, and just 2.8 times slower than the D version, and 3.4
times slower than a C version (that doesn't use too many pointer
tricks). I think this is good enough.
I can't help wishing that
On Sat, 26 Jan 2008 14:47:50 +0100, Bjoern Schliessmann
[EMAIL PROTECTED] wrote:
[EMAIL PROTECTED] wrote:
Intel processors can only process machine language[...] There's no
way for a processor to understand any higher level language, even
assembler, since it is written with hexadecimal codes
On Jan 27, 9:18 pm, glacier [EMAIL PROTECTED] wrote:
On 1月24日, 下午4时44分, Marc 'BlackJack' Rintsch [EMAIL PROTECTED] wrote:
On Wed, 23 Jan 2008 19:49:01 -0800, glacier wrote:
My second question is: is there any one who has tested very long mbcs
decode? I tried to decode a long(20+MB) xml
On Jan 27, 9:17 pm, glacier [EMAIL PROTECTED] wrote:
On 1月24日, 下午3时29分, Gabriel Genellina [EMAIL PROTECTED] wrote:
En Thu, 24 Jan 2008 04:52:22 -0200, glacier [EMAIL PROTECTED] escribió:
According to your reply, what will happen if I try to decode a long
string seperately.
I mean:
That's not the point, however. I'm trying to say that a processor
cannot read a Python script, and since the Python interpreter as
stored on disk is essentially an assembler file,
It isn't; it's an executable.
I appreciated the intelligent response I received from you earlier,
now we're
On Jan 26, 10:07 pm, Steven D'Aprano [EMAIL PROTECTED]
cybersource.com.au wrote:
On Sat, 26 Jan 2008 12:40:26 -0800, Paul Rubin wrote:
[EMAIL PROTECTED] writes:
def posmax(seq, key=lambda x:x):
return max(enumerate(seq), key=lambda k: key(k[1]))[0]
Is the Python max able to tell
Hi,
concerning to unicode, \n, \r and \r\n (0x000A, 0x000D and
0x000D+0x000A) should be threatened as newline character
at least this is how i understand it:
(http://en.wikipedia.org/wiki/Newline#Unicode)
obviously, the re module does not care, and on unix, only threatens \n
as newline char:
Arnaud Delobelle [EMAIL PROTECTED] writes:
def simple_posmax(l, key=None):
if key:
return l.index(max(l, key=key))
else:
return l.index(max(l))
def simple_posmax(l, **kw):
return l.index(max(l, **kw))
simple_posmax is more than 3x faster on my machine. It's not
On Jan 27, 11:42 am, Paul Rubin http://[EMAIL PROTECTED] wrote:
Arnaud Delobelle [EMAIL PROTECTED] writes:
def simple_posmax(l, key=None):
if key:
return l.index(max(l, key=key))
else:
return l.index(max(l))
def simple_posmax(l, **kw):
return l.index(max(l,
On Sun, 27 Jan 2008 10:55:20 +, over wrote:
On Sat, 26 Jan 2008 14:47:50 +0100, Bjoern Schliessmann
[EMAIL PROTECTED] wrote:
The script is essentially gone. I'd like to know how to read the pyc
files, but that's getting away from my point that there is a link
between python scripts and
On Sun, 27 Jan 2008 11:23:20 +, over wrote:
Don't fucking tell me about assembler, you asshole. I can read
disassembled code in my sleep.
Yes you can read it, but obviously you don't understand it.
Ciao,
Marc 'BlackJack' Rintsch
--
On Jan 27, 11:32 am, Arnaud Delobelle [EMAIL PROTECTED] wrote:
[...]
simple_posmax is more than 3x faster on my machine. It's not
surprising as even though the list is walked twice, it is all done in
C and no new objects have to be created. Then only non-C bit is when
the result of max(l)
Peter Pei wrote:
You didn't understand my question, but thanks any way.
Yes, it is true that %s already support unicode, and I did not
contradict that. But it counts the number of bytes instead of
characters, and makes things like %-20s out of alignment. If you don't
understand my
On 1月27日, 下午7时20分, John Machin [EMAIL PROTECTED] wrote:
On Jan 27, 9:17 pm, glacier [EMAIL PROTECTED] wrote:
On 1月24日, 下午3时29分, Gabriel Genellina [EMAIL PROTECTED] wrote:
En Thu, 24 Jan 2008 04:52:22 -0200, glacier [EMAIL PROTECTED] escribió:
According to your reply, what will
On 1月27日, 下午7时04分, John Machin [EMAIL PROTECTED] wrote:
On Jan 27, 9:18 pm, glacier [EMAIL PROTECTED] wrote:
On 1月24日, 下午4时44分, Marc 'BlackJack' Rintsch [EMAIL PROTECTED] wrote:
On Wed, 23 Jan 2008 19:49:01 -0800, glacier wrote:
My second question is: is there any one who has
On Sun, 27 Jan 2008 10:55:20 +, over wrote:
I can understand people thinking I'm full of beans.
Oh no, not full of beans. Full of something, but not beans.
Everything you have written about assembly, machine code, compilers,
Linux, Python and so forth has been a confused mish-mash of
Peter Pei schrieb:
I am using things like %-20s%-60s%-10s in tkinter listbox to make it
look like a table, with mono sized font like lucie system. But this does
not work with data contains Les misérables, because it is unicode, and
one byte is not neccessary one character. Now how can I
How can i get system information like CPU load and RAM usage in linux.
What about 'pystatgrab'?
It provides good info, with a limitation - it does not have CPU info
for particular CPUs, it takes just the cumulative CPU info.
http://www.i-scream.org/pystatgrab/
http://packages.debian.org/statgrab
Yes, I know.
There are several ways to work around the problem.
(Look at the innitial code I provided in this discussion start)
Fact is, every time I'm getting a script from somewhere or someone, I
have to search and replace all the affected code.
Not very conveniant.
That's why I rather would
Steven D'Aprano writes:
(1) Import the test and grab the values needed from it:
setup = from __main__ import myfunc, test
x, y = test['x'], test['y']
I don't like this one. It doesn't seem very elegant to me, and it gets
unwieldy as the complexity increases. Every item I need from test has
On Sun, 27 Jan 2008 13:41:54 +, Steven D'Aprano wrote:
On Sun, 27 Jan 2008 10:55:20 +, over wrote:
I can understand people thinking I'm full of beans.
Oh no, not full of beans. Full of something, but not beans.
Everything you have written about assembly, machine code, compilers,
I V [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
On Sun, 27 Jan 2008 05:32:40 +, Peter Pei wrote:
Yes, it is true that %s already support unicode, and I did not
contradict that. But it counts the number of bytes instead of
characters, and makes things like %-20s out of
On 2008-01-27, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:
Whatever is typed in a Python script must be converted to
binary code.
Python scripts _are_ in a binary code when the start out.
--
Grant Edwards grante Yow! What UNIVERSE is
Steven D'Aprano [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
On Sun, 27 Jan 2008 05:32:40 +, Peter Pei wrote:
You didn't understand my question, but thanks any way.
Yes, it is true that %s already support unicode, and I did not
contradict that. But it counts the number of
-
(Apologies for cross-posting)
Workshop Medical Imaging Systems within EUROSIS EUROMEDIA 2008
April 9-11, 2008, University of Porto, Porto, Portugal
Marc 'BlackJack' Rintsch [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
On Sun, 27 Jan 2008 05:32:40 +, Peter Pei wrote:
You didn't understand my question, but thanks any way.
Yes, it is true that %s already support unicode, and I did not contradict
that. But it counts the
Hi all,
An earlier post today got me thinking about quines (programs that
output themselves) in Python. I tried to find some on the web but
didn't find many ([1]). In particular I didn't find any that
corresponded to my instinctive (LISP-induced, probably) criterion:
def
Jason,
Can you give a little more detail on the problem? What's the directory
structure of a Klik package that's failing look like? What program is
trying to import what module from where that's failing?
-Bill Mill
On Jan 27, 2008 1:49 AM, Jason Taylor [EMAIL PROTECTED] wrote:
Hi
We've been
On 2008-01-27, Marc 'BlackJack' Rintsch [EMAIL PROTECTED] wrote:
I'm starting to wonder if it is possible for somebody to be
simultaneously so self-assured and so ignorant, or if we're
being trolled.
I recently learned that this is called the Dunning-Kruger effect:
The Dunning-Kruger
import threading
import time
class timer(threading.Thread):
def __init__(self,no,interval):
threading.Thread.__init__(self)
self.no=no
self.interval=interval
def run(self):
while True:
print 'Thread Object (%d), Time:%s'%(self.no,time.ctime())
There is a pattern that occurs fairly often in constructors in Python
and other OOP languages.
Let's take an example:
class Server(object):
def __init__(self, host, port, protocol, bufsize, timeout):
self.host = host
self.port = port
self.protocol = protocol
On Sun, 27 Jan 2008 16:00:42 +, Peter Pei wrote:
Marc 'BlackJack' Rintsch [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
On Sun, 27 Jan 2008 05:32:40 +, Peter Pei wrote:
You didn't understand my question, but thanks any way.
Yes, it is true that %s already support
Grant Edwards wrote:
On 2008-01-27, Marc 'BlackJack' Rintsch [EMAIL PROTECTED] wrote:
The Dunning-Kruger effect is the phenomenon wherein people who have
little knowledge think that they know more than others who have much
more knowledge.
[snip]
[snip as well]
... must restist ...
Hi
Can anyone suggest a really simple XML reader for python? I just want to
be able to do something like this:
xmlDoc = xml.open(file.xml)
element = xmlDoc.GetElement(foo/bar)
... to read the value of:
foo
bar42/bar
/foo
Thanks
Simon
--
Linux user #458601 - http://counter.li.org.
En Sat, 26 Jan 2008 05:21:52 -0200, nodrogbrown [EMAIL PROTECTED]
escribi�:
hi
i am writing code to check a folder containing images and then process
thir vals using PIL and do some calc to create a matrix of values .if
the folder has any new imgs added the program will do all calc again
Simon Pickles schrieb:
Hi
Can anyone suggest a really simple XML reader for python? I just want to
be able to do something like this:
xmlDoc = xml.open(file.xml)
element = xmlDoc.GetElement(foo/bar)
... to read the value of:
foo
bar42/bar
/foo
Since python2.5, the ElementTree
On Jan 27, 1:06 pm, coldpizza [EMAIL PROTECTED] wrote:
There is a pattern that occurs fairly often in constructors in Python
and other OOP languages.
Let's take an example:
class Server(object):
def __init__(self, host, port, protocol, bufsize, timeout):
self.host = host
En Fri, 25 Jan 2008 22:12:57 -0200, Wildemar Wildenburger
[EMAIL PROTECTED] escribi�:
Using pysqlite, I'd like to check if some dataset that I removed has
been in the database at all. Ideally I'd like pysqlite to raise an
Exception if deleting does nothing. Is that possible?
I don't think
Simon Pickles [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Hi
Can anyone suggest a really simple XML reader for python? I just want to
be able to do something like this:
xmlDoc = xml.open(file.xml)
element = xmlDoc.GetElement(foo/bar)
... to read the value of:
foo
Gabriel Genellina wrote:
En Fri, 25 Jan 2008 22:12:57 -0200, Wildemar Wildenburger
[EMAIL PROTECTED] escribi�:
Using pysqlite, I'd like to check if some dataset that I removed has
been in the database at all. Ideally I'd like pysqlite to raise an
Exception if deleting does nothing. Is that
Steven D'Aprano wrote:
I have a problem which I think could be solved by using a dict as a
namespace, in a similar way that exec and eval do.
When using the timeit module, it is very inconvenient to have to define
functions as strings. A good alternative is to create the function as
En Fri, 25 Jan 2008 20:59:41 -0200, [EMAIL PROTECTED] escribi�:
Hello, I'm trying to make a python script that take an email in (raw)
text format, and add a footer to the text (or html) body of the email.
I'm aware of the email and email.mime modules, but I can't figure out
how to identify
André wrote:
Personally, I like the idea you suggest, with the modification that I
would use . instead of @, as in
class Server(object):
def __init__(self, .host, .port, .protocol, .bufsize, .timeout):
pass
I like :)
However, you can probably cook up a decorator for this (not
Arian Sanusi wrote:
concerning to unicode, \n, \r and \r\n (0x000A, 0x000D and
0x000D+0x000A) should be threatened as newline character
the link says that your application should treat them line terminators,
not that they should all be equal to a new line character.
to split on Unicode line
Wildemar Wildenburger schrieb:
André wrote:
Personally, I like the idea you suggest, with the modification that I
would use . instead of @, as in
class Server(object):
def __init__(self, .host, .port, .protocol, .bufsize, .timeout):
pass
I like :)
However, you can probably
globophobe wrote:
In [1]: unicode_html = u'\u3055\u3080\u3044\uff0f\r\n\u3064\u3081\u305f
\u3044\r\n'
I need to turn this into an elementtree, but some of the data is
japanese whereas the rest is html. This string contains a br /.
where? br / is an element, not a character. \r and \n are
check the implementation of XMLNode class here
http://hsivonen.iki.fi/group-feed/flickrapi.py
HTH
N
On Jan 27, 2008 11:05 PM, Simon Pickles [EMAIL PROTECTED] wrote:
Hi
Can anyone suggest a really simple XML reader for python? I just want to
be able to do something like this:
xmlDoc =
It's a bit cheap, but how about
from inspect import getsource
print getsource(getsource)
or similarly
def f(g):
import inspect
return inspect.getsource(g)
print f(f)
Dan
--
http://mail.python.org/mailman/listinfo/python-list
Leo 4.4.6 final is available at:
http://sourceforge.net/project/showfiles.php?group_id=3458package_id=29106
Leo 4.4.6 fixes several recently reported bugs, all minor.
Leo is a text editor, data organizer, project manager and much more. See:
http://webpages.charter.net/edreamleo/intro.html
The
En Sun, 27 Jan 2008 12:51:51 -0200, Dox33 [EMAIL PROTECTED]
escribi�:
Yes, I know.
There are several ways to work around the problem.
(Look at the innitial code I provided in this discussion start)
Fact is, every time I'm getting a script from somewhere or someone, I
have to search and
Hallöchen!
Wildemar Wildenburger writes:
André wrote:
Personally, I like the idea you suggest, with the modification
that I would use . instead of @, as in
class Server(object):
def __init__(self, .host, .port, .protocol, .bufsize, .timeout):
pass
I like :)
However, you
Diez B. Roggisch wrote:
Just for the fun of it, I implemented a decorator:
from functools import *
from inspect import *
def autoassign(_init_):
@wraps(_init_)
def _autoassign(self, *args, **kwargs):
argnames, _, _, _ = getargspec(_init_)
for name, value in
The `trheading` module is modeled after Java's threading API.
OK. Thanks for the hint. However BufferedReader.readline() does
not block in Java, so it is still difficult to transpose.
But how can I find out *programmatically* that there is no more
input?
You can't.
How do people handle
On Jan 27, 2:48 pm, Wildemar Wildenburger
[EMAIL PROTECTED] wrote:
Diez B. Roggisch wrote:
Just for the fun of it, I implemented a decorator:
from functools import *
from inspect import *
def autoassign(_init_):
@wraps(_init_)
def _autoassign(self, *args, **kwargs):
Now there's always that style :
print x
Traceback (most recent call last):
File pyshell#15, line 1, in module
eval(x)
File string, line 2
Traceback (most recent call last):
^
SyntaxError: invalid syntax
eval(x)
Traceback (most recent call last):
Indeed, if I do this interactively, I can tell after 3 lines that I've
gotten all there is to get right now and the fourth readline() call
hangs.
Can you really?
Yes interactively: at the command prompt, you can tell when it's over
because you know the command you just sent and whether it
Hi all,
As I understand it, the idea behind duck typing is that you just take
an object and if it has the methods you want to use you use it
assuming it to be the right type of object. I'm interested in
extending this idea a bit, but I feel the sort of thing I have in mind
has already been
En Sat, 26 Jan 2008 12:10:03 -0200, J. Pablo Fernández [EMAIL PROTECTED]
escribi�:
Is it possible to replace one package with another at runtime, that is, I
have package a.blah which I want instead of b.blah, so I can inject
functionality in an existing package?
It might be done, just
Hello,
I am trying to find a good way to portably get the output of strftime()
and put it onto a dialog (I'm using PyQt, but it doesn't really matter).
The problem is that I need to decode the byte stream returned by strftime
() into Unicode.
This old bug:
Perhaps this would help, heres a list of our error reports
http://klik.atekon.de/feedback/details.php?e=ImportError
On 27/01/2008, Jason Taylor [EMAIL PROTECTED] wrote:
Hi
We've been working on klik2, http://code.google.com/p/klikclient/, which
implements OSX like application files on linux
Is there any way to solve this better?
I mean if I shouldn't convert the GBK string to unicode string, what
should I do to make SAX work?
Decode it and then encode it to utf-8 before feeding it to the parser.
The tricky part is that you also need to change the encoding declaration
in doing
En Sun, 27 Jan 2008 14:21:20 -0200, Mr Shore [EMAIL PROTECTED]
escribi�:
import threading
import time
class timer(threading.Thread):
def __init__(self,no,interval):
threading.Thread.__init__(self)
self.no=no
self.interval=interval
def run(self):
John Machin [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
On Jan 27, 9:17 pm, glacier [EMAIL PROTECTED] wrote:
On 1月24日, 下午3时29分, Gabriel Genellina [EMAIL PROTECTED]
wrote:
*IF* the file is well-formed GBK, then the codec will not mess up when
decoding it to Unicode. The usual
On 25 jan, 12:50, [EMAIL PROTECTED] wrote:
Can someone tell me the minimum requitements for Python as I can't
find it anwhere on the site. I have 3 PC's which are only 256mb RAM,
wanted to know if this was sufficenent.
The first machine I installed Python on was a pentium133 with 32mb
ram.
--
Giovanni Bajo [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Hello,
I am trying to find a good way to portably get the output of strftime()
and put it onto a dialog (I'm using PyQt, but it doesn't really matter).
The problem is that I need to decode the byte stream returned by
Slightly off-topic, but this is the best Valentine's Day card I've
seen in a while: http://unholidaycards.com/code.html
I think I just might get some for my lab.
#!/usr/bin/env python
from relationships import *
from alcohol import shot, beer
def valentines_day(self):
if self.dating:
On Jan 28, 7:47 am, Mark Tolonen [EMAIL PROTECTED]
wrote:
John Machin [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
On Jan 27, 9:17 pm, glacier [EMAIL PROTECTED] wrote:
On 1月24日, 下午3时29分, Gabriel Genellina [EMAIL PROTECTED]
wrote:
*IF* the file is well-formed GBK, then the
A while back I came across a tentative proposal from way back in 2000
for optional static typing in Python:
http://www.python.org/~guido/static-typing
Two motivations were given:
-- faster code
-- better compile-time error detection
I'd like to suggest a third, which could help extend
LookupError: unknown encoding: cp932
What Python version are you using? cp932 is supported cross-platform
since Python 2.4.
So: what is the correct code to achieve this? Will something like this
work:
data = strftime(%#c, localtime())
if os.name == nt:
data =
On Jan 27, 10:23 pm, [EMAIL PROTECTED] wrote:
[EMAIL PROTECTED]:~$ ndisasm error.txt
54push sp
0001 686973push word 0x7369
0004 206973and [bx+di+0x73],ch
0007 206E6Fand [bp+0x6f],ch
000A 7420
Olivier Lefevre [EMAIL PROTECTED] wrote:
Can you really?
Yes interactively: at the command prompt, you can tell when it's over
because you know the command you just sent and whether it requires an
answer and of which kind. Also, even if there is no answer you get a
fresh prompt when the
On Jan 27, 7:10 pm, [EMAIL PROTECTED] wrote:
Hi all,
As I understand it, the idea behind duck typing is that you just take
an object and if it has the methods you want to use you use it
assuming it to be the right type of object. I'm interested in
extending this idea a bit, but I feel the
On Jan 27, 6:19 pm, Russ P. [EMAIL PROTECTED] wrote:
A while back I came across a tentative proposal from way back in 2000
for optional static typing in Python:
http://www.python.org/~guido/static-typing
Two motivations were given:
-- faster code
-- better compile-time error
Russ P. pisze:
I noticed that Guido has expressed further interest in static typing
three or four years ago on his blog. Does anyone know the current
status of this project? Thanks.
I thought it was april fools joke?
--
Jarek Zgoda
http://zgodowie.org/
We read Knuth so you don't have to -
On Jan 27, 2:36 pm, Jarek Zgoda [EMAIL PROTECTED] wrote:
Russ P. pisze:
I noticed that Guido has expressed further interest in static typing
three or four years ago on his blog. Does anyone know the current
status of this project? Thanks.
I thought it was april fools joke?
On January
This message got huge :/
Sorry for being so cryptic and unhelpful. I now believe that you're
incurring in a (quite deep) misunderstanding and wish to make things
clear for both of us :)
On Jan 27, 6:58 am, [EMAIL PROTECTED] wrote:
On Fri, 25 Jan 2008 17:44:07 -0800 (PST), ajaksu [EMAIL
On Jan 27, 2:49 pm, André [EMAIL PROTECTED] wrote:
On Jan 27, 6:19 pm, Russ P. [EMAIL PROTECTED] wrote:
A while back I came across a tentative proposal from way back in 2000
for optional static typing in Python:
http://www.python.org/~guido/static-typing
Two motivations were given:
On Jan 27, 2:23 pm, Martin Saturka [EMAIL PROTECTED] wrote:
How can i get system information like CPU load and RAM usage in linux.
What about 'pystatgrab'?
It provides good info, with a limitation - it does not have CPU info
for particular CPUs, it takes just the cumulative CPU
Russ P. pisze:
I noticed that Guido has expressed further interest in static typing
three or four years ago on his blog. Does anyone know the current
status of this project? Thanks.
I thought it was april fools joke?
On January 21, 2000? Which calendar do you use?
Static typing in Python
Hi all. I'm just getting introduced to Python (mostly through Dive
Into Python), and I've decided to use it for a project where I have to
write my own Genetic Algorithm. Even if you don't know about GAs, you
might be able to help with an issue I'm having. I'm just starting the
project off, so I'm
On Jan 27, 3:08 pm, Jarek Zgoda [EMAIL PROTECTED] wrote:
Russ P. pisze:
I noticed that Guido has expressed further interest in static typing
three or four years ago on his blog. Does anyone know the current
status of this project? Thanks.
I thought it was april fools joke?
On January
On Jan 27, 11:00 pm, Russ P. [EMAIL PROTECTED] wrote:
On Jan 27, 2:49 pm, André [EMAIL PROTECTED] wrote:
Perhaps this:http://www.python.org/dev/peps/pep-3107/mightbe
relevant?
André
Thanks. If I read this correctly, this PEP is on track for Python 3.0.
Wonderful!
Note that annotations
1 - 100 of 203 matches
Mail list logo