python and web pages287 (11/19/2009 7:10:32 AM) Hi,
Here is my situation:
I'm using the command line, as in, I'm not starting gnome or kde (I'm on
linux.)
I have a string of text attached to a variable,. So I need to use one of
the browsers on linux, ... Daniel
semantics of [:]873 (11/20/2009 4:15:55 PM) Could someone help confirm/clarify the semantics of the [:] operator
in Python?
a = range(51,55)
############# 1 ##################
b = a[:] # b receives a copy of a, but they are independent
# The... Esmail
Is an interactive command a block?773 (11/19/2009 8:37:17 PM) The CPython 3.1.1 language reference �4.1 says
"Each command typed interactively is a block."
It also says
"If a name is bound in a block, it is a local variable of that block, unless
declar... Alf
Is there something similar to list comprehension in dict?888 (11/20/2009 3:18:04 AM) I'm wondering if there is something similar to list comprehension for
dict (please see the example code below).
d = dict(one=1, two=2)
print d
def fun(d):#Is there a way similar to list comprehension ... Peng
No duplicate variable288 (11/20/2009 4:38:54 PM) class A(object):
def __init__(self, value=0.):
self.value = value
class B(A):
def __init__(self, value=None):
A.__init__(self)
self.value = value
obj = B()
When "B"... King
PyQt4 4.4.4 : a bug with highlightBlock ?260 (11/18/2009 10:47:02 AM) Hello everybody,
I've been trying to do some syntax highlighting using PyQt4. I ported
the example given in the documentation of Qt4 to Python. It works fine
on my computer at work (which has PyQt4 version... alexis.flesch(5)
Regexp and multiple groups (with repeats)183 (11/20/2009 12:03:04 PM) Hello,
>>> r=re.compile(r'(?:[a-zA-Z]:)([\\/]\w+)+')
>>> r.search(r'c:/tmp/spam/eggs').groups()
('/eggs',)
Obviously, I would like to capture all groups:
('/tmp', '/spam', '/eggs')
But it seems ... mk
Announcement: depikt - the minimalistic python gate to gtk086 (11/20/2009 10:51:10 AM) Hi all,
these days i make depikt, a python C-extension for building apps with
gtk. It was a challenge for me and big fun. From its short description
on sourceforge.net:
"Python-3 wrappers for GTK. A min... joost(13)
Book: Programming Python 3 (Second Edition) now available093 (11/20/2009 10:20:17 AM) Hi,
I'm delighted to announce that a new edition of my Python 3 book is
now available in the U.S.
"Programming in Python 3 (Second Edition):
A Complete Introduction to the Python Language"
ISBN 0321680... list537(29)
checking 'type' programmatically093 (11/20/2009 10:10:18 AM)
Disclaimer: this is for exploring and debugging only. Really.
I can check type or __class__ in the interactive interpreter:
Python 2.6.2 (r262:71600, Jun 16 2009, 16:49:04)
[GCC 4.1.2 20080704 (Red Hat... mk