I am pleased to announce the 0.1.1 version of PySWIP.
PySWIP is a GPL'd Python/SWI-Prolog bridge enabling to query SWI-
Prolog in your Python programs.
Example:
from pyswip.util import PrologRunner
prolog = PrologRunner()
prolog.query(assertz(father(michael,john)).)
[{}]
Karrigell is a flexible Python web framework, with a clear and
intuitive syntax. It is independant from any database, ORM or
templating engine, and lets the programmer choose between a variety of
coding styles
The main new features in version 2.3.5 are :
- a first version of the integration of
On Sat, 26 May 2007 18:48:45 -0700, Steve Howell wrote:
It also has a ComplexNumber class, but I don't want to
scare away mathphobes.
Is it as short as this one-liner?
ComplexNumber = complex
--
Steven.
--
http://mail.python.org/mailman/listinfo/python-list
Paul McGuire schrieb:
I'm starting a new thread for this topic, so as not to hijack the one
started by Steve Howell's excellent post titled ten small Python
programs.
In that thread, there was a suggestion that these examples should
conform to PEP-8's style recommendations, including use of
On May 26, 2007, at 11:29 PM, [EMAIL PROTECTED] wrote:
e.g.
rtfm = (100,100)
im.getpixel(rtfm)
--
http://mail.python.org/mailman/listinfo/python-list
En Sat, 26 May 2007 23:00:45 -0300, momobear [EMAIL PROTECTED] escribió:
I feel really puzzled about fellowing code, please help me finger out
what problem here.
import threading
class workingthread(threading.Thread):
def __init__(self):
self.quitEvent =
Steven Bethard wrote:
I just tried to upload new versions of the argparse module to PyPI, but
it seems like I can no longer upload Windows installers:
$ setup.py sdist bdist_wininst upload
...
running upload
Submitting dist\argparse-0.8.0.zip to http://www.python.org/pypi
Stefan Sonnenberg-Carstens wrote:
Paul McGuire schrieb:
I'm starting a new thread for this topic, so as not to hijack the one
started by Steve Howell's excellent post titled ten small Python
programs.
In that thread, there was a suggestion that these examples should
conform to PEP-8's style
--- Steven D'Aprano
[EMAIL PROTECTED] wrote:
On Sat, 26 May 2007 18:48:45 -0700, Steve Howell
wrote:
It also has a ComplexNumber class, but I don't
want to
scare away mathphobes.
Is it as short as this one-liner?
ComplexNumber = complex
The It above refers to *the* Python
--- Steven D'Aprano wrote:
On Sat, 26 May 2007 18:48:45 -0700, Steve Howell
wrote:
It also has a ComplexNumber class, but I don't
want to
scare away mathphobes.
Is it as short as this one-liner?
ComplexNumber = complex
Along the idea of not reinventing a class from the
On May 27, 4:20 pm, Steven Bethard [EMAIL PROTECTED] wrote:
Steven Bethard wrote:
I just tried to upload new versions of the argparse module to PyPI, but
it seems like I can no longer upload Windows installers:
[snip]
That seems a little weird to me. Are the bdist_wininst exe files really
I don't know of any in Python, but an open source image processing package in
Java has been developed at Stanford University - http://www.gemident.net
GemIdent . GemIdent was originally designed to segment cells from
miscroscopic images and, more generally, can identify objects of interest
and
Paul McGuire wrote:
I was under the impression that lower_case_with_underscores was a
dated recommendation, and that recent practice is more inclusive of
mixedCase style identifiers. On the contrary, Steven Bethard
straightened me out, saying that PEP-8 used to accept either style,
but has
On May 27, 1:25 am, Steven Bethard [EMAIL PROTECTED] wrote:
Stefan Sonnenberg-Carstens wrote:
Paul McGuire schrieb:
I'm starting a new thread for this topic, so as not to hijack the one
started by Steve Howell's excellent post titled ten small Python
programs.
In that thread, there was
You might be interested in the ndimage module of scipy:
http://www.scipy.org/SciPyPackages/Ndimage
If you need a very serious image processing framework, ITK is might be very
interesting:
http://www.itk.org/
If so, have a look at the more Pythonic interface developed for it:
Cameron Laird [EMAIL PROTECTED] wrote:
In article [EMAIL PROTECTED],
Dennis Lee Bieber [EMAIL PROTECTED] wrote:
.
.
.
Did you know that the first military smokeless powder
round was for the French Lebel? - It threw a bronze
ball, and could punch through a single brick wall.
Cameron Laird [EMAIL PROTECTED] wrote:
.
.
Ha! It's interesting, especially for computerists, to consider
how some technologies plateau: steam car speeds, fresco paint-
ing, dry-stone walls, ...
From what I remember from my reading, the Stanley Steamer
had a reputation as a Hot Rod
Hello,
I need to develop an web applications that meet the following requirements:
- 2 layers: the first one is the user interface (browser) and the second
one is the interaction with the operacional system of the server.
- the second layer must be developed using Python.
I'd like to know
brad wrote:
Kevin Walzer wrote:
2. wxPython is big, harder to learn than Tkinter, but looks good on
Mac, Windows, and *Nix. It will require users to install a lot of
extra stuff (or you'll have to bundle the extra stuff).
PyInstaller builds binaries beautifully from raw py source. No
Paul McGuire [EMAIL PROTECTED] writes:
At this point, I realized that I was taking things too far
off-topic, so I decided to start a new thread.
So, uh, what's the purpose of this thread? Did you have a specific
point to start off with, or a question to ask?
--
\ It seems intuitively
Hi all
I posted earlier on this but have changed my approach so here is my
latest attempt at solving a problem. I have been working on this for
around 12 hours straight and am still struggling with it.
Write a program that reads the values for a random list of cards from
a file, where each line
I got it.
Pass python challenge chapter 7.
--
http://mail.python.org/mailman/listinfo/python-list
In [EMAIL PROTECTED], mark wrote:
Hi all
I posted earlier on this but have changed my approach so here is my
latest attempt at solving a problem. I have been working on this for
around 12 hours straight and am still struggling with it.
Write a program that reads the values for a random
No, this is not a bug. You must not call Thread.run(), use Thread.start()
instead - else your code won't run in a different thread of execution. See
http://docs.python.org/lib/thread-objects.htmlon how to use Thread
objects - and note that you should *only* override __init__ and run, if
On May 27, 12:19 pm, mark [EMAIL PROTECTED] wrote:
Hi all
I posted earlier on this but have changed my approach so here is my
latest attempt at solving a problem. I have been working on this for
around 12 hours straight and am still struggling with it.
Write a program that reads the values
Hello -
Background:
I'm not a coder, but I got a degree in Chem Engg about 7 years ago. I
have done some
coding in my life, and I'm only beginning to pick up Python. So assume
that I'm very stupid
when and if you are kind enough to help me out.
Problem:
I need an SMS server running on my WinXP
En Sun, 27 May 2007 07:19:15 -0300, mark [EMAIL PROTECTED] escribió:
I posted earlier on this but have changed my approach so here is my
latest attempt at solving a problem. I have been working on this for
around 12 hours straight and am still struggling with it.
Almost done. Just two things:
Instead of extending join(), write a specific method to signal the
quitEvent or just let the caller signal it. And I don't see in this
example why do you need two different events (one on the thread, another
on the service controller), a single event would suffice.
I don't think a single
On May 26, 1:43 pm, Steve Howell [EMAIL PROTECTED] wrote:
--
parentRabbits, babyRabbits = (1, 1)
while babyRabbits 100:
print 'This generation has %d rabbits' %
babyRabbits
parentRabbits, babyRabbits = (babyRabbits,
parentRabbits + babyRabbits)
--
On Sun, 2007-05-27 at 07:30 +, OKB (not okblacke) wrote:
Underscores are harder to type than any alphanumeric character.
This is a discussion about underscores versus capital letters denoting
the word boundaries in identifiers. How is an underscore harder to type
than a capital
I have some working code, but I realized it is just the way I would
write it in C, which means there is probably a better (more pythonic)
way of doing it.
Here's the section of code:
accumulate = firstIsCaps = False
accumStart = i = 0
while i len(words):
firstIsCaps =
--- Ben Finney [EMAIL PROTECTED]
wrote:
Paul McGuire [EMAIL PROTECTED] writes:
At this point, I realized that I was taking things
too far
off-topic, so I decided to start a new thread.
So, uh, what's the purpose of this thread? Did you
have a specific
point to start off with, or a
--- Marc 'BlackJack' Rintsch [EMAIL PROTECTED] wrote:
Maybe it's easier to use a key function instead of a
compare function. A
key function receives an element and must return
something that is then
sorted and the element ends up where the computed
key is in the sorted
list. Little
Bill Jackson [EMAIL PROTECTED] writes:
Alexander Schmolck wrote the following on 05/25/2007 02:33 PM:
I have no idea whether this will resolve your problem, but you could try
updating to 0.90 (BTW what happens if you do axis([0,128,0,128])).
The problem appears to be with a matplotlibrc
--- mark [EMAIL PROTECTED] wrote:
Hi all
I posted earlier on this but have changed my
approach so here is my
latest attempt at solving a problem. I have been
working on this for
around 12 hours straight and am still struggling
with it.
Write a program that reads the values for a
En Sun, 27 May 2007 10:44:01 -0300, Eric [EMAIL PROTECTED] escribió:
I have some working code, but I realized it is just the way I would
write it in C, which means there is probably a better (more pythonic)
way of doing it.
Here's the section of code:
accumulate = firstIsCaps = False
On Sun, 27 May 2007 06:44:01 -0700, Eric wrote:
words is a big long array of strings. What I want to do is find
consecutive sequences of words that have the first letter capitalized,
and then call doSomething on them. (And you can ignore the fact that
it won't find a sequence at the very
--- Eric [EMAIL PROTECTED] wrote:
I have some working code, but I realized it is just
the way I would
write it in C, which means there is probably a
better (more pythonic)
way of doing it.
Here's the section of code:
accumulate = firstIsCaps = False
accumStart = i = 0
In [EMAIL PROTECTED], Steve Howell
wrote:
def key_func(item):
return (len(item), item)
data = ['viking', 'spam', 'parrot', 'ham', 'eric']
data.sort(key=key_func)
print data
Marc, when did the key feature get introduced, 2.4 or
2.5? I'm asking on behalf of the newbie, who's going
En Sun, 27 May 2007 10:20:49 -0300, Carsten Haese [EMAIL PROTECTED]
escribió:
On Sun, 2007-05-27 at 07:30 +, OKB (not okblacke) wrote:
Underscores are harder to type than any alphanumeric character.
This is a discussion about underscores versus capital letters denoting
the word
--- Gabriel Genellina [EMAIL PROTECTED] wrote:
Underscores are not always easily available on non
us-layout keyboards,
like \ and @ and many other special characters. A
language that requires
more symbols than the 26 english letters has to make
room somewhere -
keyboards usually
[rohit]
i want to detect all file change operations(rename,delete,create)
on ALL THE DRIVES of the hard disk
using the method ReadDirectoryChanges API , i.e program no. 3 in the
webpagehttp://tgolden.sc.sabren.com/python/win32_how_do_i/watch_directory_fo...
.
Please suggest some
DJ Fadereu wrote:
I need an SMS server running on my WinXP PC, as soon as possible. I'm
currently using a Nokia 6300 phone which has the S60 platform. I
downloaded the PySMS by Dave Berkeley from
http://www.wordhord.co.uk/pysms.html and started testing it, but I
haven't been able to get it
John Machin wrote:
On May 27, 4:20 pm, Steven Bethard [EMAIL PROTECTED] wrote:
Steven Bethard wrote:
I just tried to upload new versions of the argparse module to PyPI, but
it seems like I can no longer upload Windows installers:
[snip]
That seems a little weird to me. Are the bdist_wininst
--- BartlebyScrivener [EMAIL PROTECTED] wrote:
On May 26, 1:43 pm, Steve Howell
[EMAIL PROTECTED] wrote:
--
# def defines a method in Python
def tax(itemCharge, taxRate = 0.05):
return itemCharge * taxRate
print '%.2f' % tax(11.35)
print '%.2f' %
En Sun, 27 May 2007 09:07:36 -0300, momobear [EMAIL PROTECTED] escribió:
Instead of extending join(), write a specific method to signal the
quitEvent or just let the caller signal it. And I don't see in this
example why do you need two different events (one on the thread, another
on the
On May 26, 8:21 pm, John Machin [EMAIL PROTECTED] wrote:
On May 27, 5:25 am, erikcw [EMAIL PROTECTED] wrote:
On May 25, 11:28 am, Carsten Haese [EMAIL PROTECTED] wrote:
On Fri, 2007-05-25 at 09:51 -0500, Dave Borne wrote:
I'm trying to run the following query:
...
En Sun, 27 May 2007 12:19:03 -0300, Steven Bethard
[EMAIL PROTECTED] escribió:
Also, I couldn't get the StringIO code from there to work:
import StringIO
content = open('argparse-0.8.0.win32.exe').read()
Use open(...,rb).read() - the b is important on Windows.
--
Gabriel Genellina
--- BartlebyScrivener [EMAIL PROTECTED] wrote:
For the person new to programming (doesn't come from
C or other
languages), I think you need to add a separate
explanation of string
formatting and how it works, or at least add a
comment that tells them
you are using string formatting so
Hi all,
I'm a PHP5 developer looking to broaden my horizons so to speak by
learning a new language. I emphasize the 5 in PHP since I have fully
engrossed myself in the full OOP of version 5 with my own ground-up
projects as well as some work with PRADO (http://pradosoft.com)
I've dabbled with a
Steve Howell wrote:
# def defines a method in Python
def say_hello(name):
print 'hello', name
say_hello('Jack')
say_hello('Jill')
Doesn't def define methods *xor* functions, depending on the context?
And in this example, say_hello (*yuck*, underscores ...) is
quoth the romiro:
Hi all,
...
Anyway, my first question was if anyone knows of a tutorial that
focuses on PHP - Python learning, in such that there might be a block
of PHP code alongside an example of how to do the same thing in
Python. One example of something I've already mapped a
En Sun, 27 May 2007 12:41:36 -0300, romiro [EMAIL PROTECTED] escribió:
Anyway, my first question was if anyone knows of a tutorial that
focuses on PHP - Python learning, in such that there might be a block
of PHP code alongside an example of how to do the same thing in
I don't know of a
--- romiro [EMAIL PROTECTED] wrote:
Anyway, my first question was if anyone knows of a
tutorial that
focuses on PHP - Python learning, in such that
there might be a block
of PHP code alongside an example of how to do the
same thing in
Python.
I know exactly what you mean, and I
On May 27, 9:41 am, romiro [EMAIL PROTECTED] wrote:
Hi all,
I'm a PHP5 developer looking to broaden my horizons so to speak by
learning a new language. I emphasize the 5 in PHP since I have fully
engrossed myself in the full OOP of version 5 with my own ground-up
projects as well as some
On May 27, 3:35 am, Ben Finney [EMAIL PROTECTED]
wrote:
Paul McGuire [EMAIL PROTECTED] writes:
At this point, I realized that I was taking things too far
off-topic, so I decided to start a new thread.
So, uh, what's the purpose of this thread? Did you have a specific
point to start off
--- romiro [EMAIL PROTECTED] wrote:
I've recently tried
C#, a very short
lived re-attempt at C++ and Java, and Ruby.
To the extend that you're familiar with C++/Java/Ruby,
you may find this link as an interesting way to see
how Python looks:
http://www.dmh2000.com/cjpr/cmpframe.html
John, thanks for your reply. I will then use the files as input to generate
an index. So the
files are temporary, and provide some attributes in the index. So I do this
multiple times
to gather different attributes, merge, etc.
John Machin [EMAIL PROTECTED] wrote in message
news:[EMAIL
Steven Bethard wrote:
Gabriel Genellina wrote:
En Sun, 27 May 2007 12:19:03 -0300, Steven Bethard
[EMAIL PROTECTED] escribió:
Also, I couldn't get the StringIO code from there to work:
import StringIO
content = open('argparse-0.8.0.win32.exe').read()
Use open(...,rb).read() - the b
===
Announcing argparse 0.8
===
The argparse module is an optparse-inspired command line parser that
improves on optparse by supporting:
* positional arguments
* sub-commands
* required options
* options with a variable number of args
* better usage
--- erikcw [EMAIL PROTECTED] wrote:
('SELECT payment_id FROM amember_payments WHERE
member_id=%s AND
expire_date NOW() AND completed=1 AND
(product_id 11 AND product_id
21)', (1608L,))
()
Here is a copy of the table schema and the first 2
rows.
Does your table actually
--- Wildemar Wildenburger [EMAIL PROTECTED]
wrote:
Steve Howell wrote:
# def defines a method in Python
def say_hello(name):
print 'hello', name
say_hello('Jack')
say_hello('Jill')
Doesn't def define methods *xor* functions,
depending on the context?
In article [EMAIL PROTECTED],
Gabriel Genellina [EMAIL PROTECTED] wrote:
En Sun, 27 May 2007 12:41:36 -0300, romiro [EMAIL PROTECTED] escribió:
Anyway, my first question was if anyone knows of a tutorial that
focuses on PHP - Python learning, in such that there might be a block
of PHP code
Steve Howell wrote:
--- Steven Bethard [EMAIL PROTECTED] wrote:
Very cool! Do you mind putting this up on the Wiki
somewhere so that we
can link to it more easily? Maybe something like:
http://wiki.python.org/moin/SimplePrograms
Done.
I think I would rewrite the current
Bejeezus. The description of groupby in the docs is a poster child
for why the docs need user comments. Can someone explain to me in
what sense the name 'uniquekeys' is used this example:
import itertools
mylist = ['a', 1, 'b', 2, 3, 'c']
def isString(x):
s = str(x)
if s == x:
--- 7stud [EMAIL PROTECTED] wrote:
Bejeezus. The description of groupby in the docs is
a poster child
for why the docs need user comments. Can someone
explain to me in
what sense the name 'uniquekeys' is used this
example: [...]
The groupby method has its uses, but it's behavior is
On May 27, 11:28 am, Steve Howell [EMAIL PROTECTED] wrote:
--- 7stud [EMAIL PROTECTED] wrote:
Bejeezus. The description of groupby in the docs is
a poster child
for why the docs need user comments. Can someone
explain to me in
what sense the name 'uniquekeys' is used this
example:
I have a set of functions to wrap a library. For example,
mylib_init()
mylib_func()
mylib_exit()
or
handle = mylib_init()
mylib_func(handle)
mylib_exit(handle)
In order to call mylib_func(), mylib_init() has to be called once.
When it's done, or when program exits, mylib_exit() should
be
--- 7stud [EMAIL PROTECTED] wrote:
Bejeezus. The description of groupby in the docs is
a poster child
for why the docs need user comments.
I would suggest an example with a little more
concreteness than what's currently there.
For example, this code...
import itertools
syslog_messages
The APL 2007 conference, sponsored by ACM SIGAPL,
has as its principal theme Arrays and Objects and,
appropriately, is co-located with OOPSLA 2007, in
Montreal this October.
APL 2007 starts with a tutorial day on Sunday, October 21, followed by a
two-day program on Monday and Tuesday, October
--- Steven Bethard [EMAIL PROTECTED] wrote:
I think I would rewrite the current unit-testing
example to use the
standard library unittest module::
# Let's write reusable code, and unit test it.
def add_money(amounts):
# do arithmetic in pennies so as not to
--- Steven Bethard [EMAIL PROTECTED] wrote:
I think I would rewrite the current unit-testing
example to use the
standard library unittest module::
# Let's write reusable code, and unit test it.
def add_money(amounts):
# do arithmetic in pennies so as not to
Stefan Sonnenberg-Carstens wrote:
Paul McGuire schrieb:
I'm starting a new thread for this topic, so as not to hijack the one
started by Steve Howell's excellent post titled ten small Python
programs.
In that thread, there was a suggestion that these examples should
conform to PEP-8's
Carsten Haese wrote:
On Sun, 2007-05-27 at 07:30 +, OKB (not okblacke) wrote:
Underscores are harder to type than any alphanumeric
character.
This is a discussion about underscores versus capital letters
denoting the word boundaries in identifiers. How is an
--- 7stud [EMAIL PROTECTED] wrote:
I'd settle for a simple explanation of what it does
in python.
The groupby function prevents you have from having to
write awkward (and possibly broken) code like this:
group = []
lastKey = None
for item in items:
newKey = item.key()
--- Steve Howell [EMAIL PROTECTED] wrote:
--- 7stud [EMAIL PROTECTED] wrote:
Bejeezus. The description of groupby in the docs
is
a poster child
for why the docs need user comments.
Regarding the pitfalls of groupby in general (even
assuming we had better documentation), I
Steve Howell wrote:
--- Steven Bethard [EMAIL PROTECTED] wrote:
I think I would rewrite the current unit-testing
example to use the
standard library unittest module::
# Let's write reusable code, and unit test it.
def add_money(amounts):
# do arithmetic in pennies so as
OKB (not okblacke) [EMAIL PROTECTED] writes:
Underscores are harder to type than any alphanumeric character.
I know of no keyboard layout in common use where it's more complicated
than Shift+some key, exactly the same as a single uppercase
letter. Care to enlighten me?
--
\
Stefan Sonnenberg-Carstens [EMAIL PROTECTED] writes:
I prefer mixedCaseStyle, and I think that should be standard,
I dislike it. It's inconsistent, and confusingly similar to
TitleCaseStyle used for class names in Python.
as this style is commonly used in all major languages , for
example
Steve Howell wrote:
--- Steven Bethard [EMAIL PROTECTED] wrote:
I think I would rewrite the current unit-testing
example to use the
standard library unittest module::
# Let's write reusable code, and unit test it.
def add_money(amounts):
# do arithmetic in pennies so
--- Steven Bethard [EMAIL PROTECTED] wrote:
Steve Howell wrote:
--- Steven Bethard [EMAIL PROTECTED]
wrote:
I think I would rewrite the current unit-testing
example to use the
standard library unittest module::
# Let's write reusable code, and unit test
it.
def
Steve Howell wrote:
--- Steven Bethard [EMAIL PROTECTED] wrote:
Steve Howell wrote:
--- Steven Bethard [EMAIL PROTECTED]
wrote:
I think I would rewrite the current unit-testing
example to use the
standard library unittest module::
# Let's write reusable code, and unit test
it.
--- Steven Bethard [EMAIL PROTECTED] wrote:
Have you tried py.test?
http://codespeak.net/py/dist/test.html
I've heard good things about it, but haven't gotten
around to trying it
yet. Here's a two-line test suite from the page
above:
def test_answer():
assert 42
--- Steven Bethard [EMAIL PROTECTED] wrote:
Maybe this is the first good example that
motivates a
hyperlink to alternatives. Would you accept the
idea
that we keep my original example on the
SimplePrograms
page, but we link to a UnitTestingPhilosophies
page,
and we show your
On Sun, 2007-05-27 at 10:17 -0700, 7stud wrote:
Bejeezus. The description of groupby in the docs is a poster child
for why the docs need user comments. Can someone explain to me in
what sense the name 'uniquekeys' is used this example:
import itertools
mylist = ['a', 1, 'b', 2, 3,
Paul McGuire [EMAIL PROTECTED] writes:
code about once/year. But it does mean that additions to the external
API to the std lib will contain method calls such as get_files,
send_message, delete_record, etc. I think this just promotes a
perception of Python as so last century.
I think you've
Steve Howell wrote:
--- erikcw [EMAIL PROTECTED] wrote:
('SELECT payment_id FROM amember_payments WHERE
member_id=%s AND
expire_date NOW() AND completed=1 AND
(product_id 11 AND product_id
21)', (1608L,))
()
Here is a copy of the table schema and the first 2
rows.
Does your table
Steve Howell schrieb:
--- Steve Howell [EMAIL PROTECTED] wrote:
--- 7stud [EMAIL PROTECTED] wrote:
Bejeezus. The description of groupby in the docs
is
a poster child
for why the docs need user comments.
Regarding the pitfalls of groupby in general (even
assuming we had better
erikcw wrote:
On May 26, 8:21 pm, John Machin [EMAIL PROTECTED] wrote:
On May 27, 5:25 am, erikcw [EMAIL PROTECTED] wrote:
On May 25, 11:28 am, Carsten Haese [EMAIL PROTECTED] wrote:
On Fri, 2007-05-25 at 09:51 -0500, Dave Borne wrote:
I'm trying to run the following query:
...
Steven Bethard [EMAIL PROTECTED] writes:
I think I would rewrite the current unit-testing example to use the
standard library unittest module::
I think these days we're supposed to like doctest better than unittest.
--
http://mail.python.org/mailman/listinfo/python-list
On May 27, 2007, at 4:01 PM, Steve Holden wrote:
erikcw wrote:
On May 26, 8:21 pm, John Machin [EMAIL PROTECTED] wrote:
On May 27, 5:25 am, erikcw [EMAIL PROTECTED] wrote:
On May 25, 11:28 am, Carsten Haese [EMAIL PROTECTED] wrote:
On Fri, 2007-05-25 at 09:51 -0500, Dave Borne wrote:
Ben Finney [EMAIL PROTECTED] wrote:
Is C no longer a major language? The long-standing convention there
is for lower_case_with_underscores.
Which dates back to the days of ASR-33's which only had one case (upper
case, as a matter of fact). Does nobody else remember C compilers which
accepted
Hi,
I'm trying to turn o list of objects into a dictionary using a list
comprehension.
Something like
entries = {}
[entries[int(d.date.strftime('%m'))] = d.id] for d in links]
I keep getting errors when I try to do it. Is it possible? Do
dictionary objects have a method equivalent to
On May 27, 4:01 pm, Steve Holden [EMAIL PROTECTED] wrote:
erikcw wrote:
On May 26, 8:21 pm, John Machin [EMAIL PROTECTED] wrote:
On May 27, 5:25 am, erikcw [EMAIL PROTECTED] wrote:
On May 25, 11:28 am, Carsten Haese [EMAIL PROTECTED] wrote:
On Fri, 2007-05-25 at 09:51 -0500, Dave Borne
On May 27, 1:55 pm, erikcw [EMAIL PROTECTED] wrote:
Hi,
I'm trying to turn o list of objects into a dictionary using a list
comprehension.
Something like
entries = {}
[entries[int(d.date.strftime('%m'))] = d.id] for d in links]
I keep getting errors when I try to do it. Is it
erikcw schrieb:
Hi,
I'm trying to turn o list of objects into a dictionary using a list
comprehension.
Something like
entries = {}
[entries[int(d.date.strftime('%m'))] = d.id] for d in links]
I keep getting errors when I try to do it. Is it possible? Do
dictionary objects have a
On 27 mai, 22:55, erikcw [EMAIL PROTECTED] wrote:
Hi,
I'm trying to turn o list of objects into a dictionary using a list
comprehension.
Something like
entries = {}
[entries[int(d.date.strftime('%m'))] = d.id] for d in links]
I keep getting errors when I try to do it. Is it possible?
I have this code:
import xml.parsers.expat
def start_element(name, attrs):
print 'Start element:', name, attrs
def end_element(name):
print 'End element:', name
def char_data(data):
print 'Character data:', repr(data)
p = xml.parsers.expat.ParserCreate()
p.StartElementHandler =
--- paul [EMAIL PROTECTED] wrote:
Regarding the pitfalls of groupby in general (even
assuming we had better documentation), I invite
people
to view the following posting that I made on
python-ideas, entitled SQL-like way to manipulate
Python data structures:
LINQ?
Maybe. I
--- Carsten Haese [EMAIL PROTECTED] wrote:
On Sun, 2007-05-27 at 10:17 -0700, 7stud wrote:
Bejeezus. The description of groupby in the docs
is a poster child
for why the docs need user comments. Can someone
explain to me in
what sense the name 'uniquekeys' is used this
example:
1 - 100 of 147 matches
Mail list logo