Lada Kugis writes:
> I'm coming from fortran and c background so I'm certainly biased by
> them. But if you could explain one thing to me:
>
> in fortran for example:
> for i=1,n
> goes from 1,2,3,4,...,n
>
> in python for example:
> for i in range(1,n)
> goes from 1,2,3,4,...,n-1
> (that is, it
On Wed, 01 Apr 2009 19:13:33 +0200, TP wrote:
> Hi everybody,
>
> Try the following python statements:
>
"%.40f" % 0.222
> '0.098864108374982606619596'
float( 0.222)
> 0.1
Remove the leading quote
On Apr 1, 4:59 pm, Dennis Lee Bieber wrote:
> On Tue, 31 Mar 2009 14:26:08 -0700 (PDT), ritu
> declaimed the following in
> gmane.comp.python.general:
>
>
>
> > if ( ( -B $filename ||
> > $filename =~ /\.pdf$/ ) &&
> > -s $filename > 0 ) {
> > return(1);
> > }
>
>
The TIOBE programming community index has some interesting data this
month.
http://www.tiobe.com/content/paperinfo/tpci/index.html
* The top three languages, C, C++ and Java between them have a combined
rating approaching 50%;
* Python has increased popularity over the last year, from positio
On Apr 1, 12:44 am, 一首诗 wrote:
> I got the same problem when writing C#/C++ when I have to provide a
> lot of method to my code's user. So I create a big class as the entry
> point of my code. Although these big classes doesn't contains much
> logic, they do grow bigger and bigger.
This seems
this is great, thanks... we have used generators to create something
akin to a cooperative tasking environment... not to implement
multitasking, but to be able to control low level data processing
scripts. These scripts, written as generators, yield control to a
control loop which then can pause,
On Apr 2, 8:39 am, John Machin wrote:
> On Apr 1, 4:59 pm, Dennis Lee Bieber wrote:
>
>
>
> > On Tue, 31 Mar 2009 14:26:08 -0700 (PDT), ritu
> > declaimed the following in
> > gmane.comp.python.general:
>
> > > if ( ( -B $filename ||
> > > $filename =~ /\.pdf$/ ) &&
> > > -s
On 1 Apr, 21:43, Gary Herron wrote:
> Simon Hibbs wrote:
> > I'm trying to dump a snapshot of my application window to the
> > clipboard. I can use ImageGrab in PIL to get the screen data into a
> > PIL image object, which i have converted to a bitmap using ImageWin,
> > but when I try to pass thi
On Apr 2, 2:10 am, John Posner wrote:
> Dennis Lee Bieber presented a code snippet with two consecutive statements
> that made me think, "I'd code this differently". So just for fun ... is
> Dennis's original statement or my "_alt" statement more idiomatically
> Pythonic? Are there even more Pytho
On Mar 31, 10:03 pm, Terry Reedy wrote:
> At PyCon2008, David Beazley presented an excellent talk on generators.
> Generator Tricks for Systems
> Programmershttp://www.dabeaz.com/generators/index.html
>
> At PyCon2009, he followed up with another talk on more advanced
> generator usage, which Gui
Nico Grubert wrote:
Dear Python developers... I have the following (sorted) list
I want to remove all paths x from the list if there is a path y in the
list which is part of x so y.startswith(x) is true.
The list I want to have is:
['/notebook', '/desktop', '/server/hp/proliant']
Any ide
On Apr 1, 2:32 pm, Arnaud Delobelle wrote:
> Lada Kugis writes:
> > I'm coming from fortran and c background so I'm certainly biased by
> > them. But if you could explain one thing to me:
>
> > in fortran for example:
> > for i=1,n
> > goes from 1,2,3,4,...,n
>
> > in python for example:
> > for
In message <13298fc5-5024-4343-
bf5a-7e271a08d...@o11g2000yql.googlegroups.com>, Michele Simionato wrote:
> However, there are situations when you need thousands of lightweight
> threads of execution ;;;
The Linux kernel has been tested running hundreds of thousands of threads.
--
http://mail.py
Lada Kugis wrote:
> On 01 Apr 2009 01:26:41 GMT, Steven D'Aprano
> wrote:
>
>
>> Why Python (and other languages) count from zero instead of one, and
>> why half-open intervals are better than closed intervals:
>>
>> http://www.johndcook.com/blog/2008/06/26/why-computer-scientists-count-from-z
On Wed, 01 Apr 2009 14:53:34 +0100, Evan wrote:
Hello -
I'm trying to decode the pcap file which is packet capture by tcpdump
or wireshark. Is there a python module that I can use it for this
problem?
Can python-libpcap or pycap or dpkt do that?
A quick browse of the pypcap website sugge
On Wed, 01 Apr 2009 15:12:27 +0100, Lada Kugis
wrote:
On 01 Apr 2009 08:06:28 GMT, Steven D'Aprano
wrote:
There are advantages and disadvantages to both systems, but on balance,
I
think that zero-based is a better system for programming, and one-based
for natural language.
Nicely put
On Wed, 01 Apr 2009 05:15:19 +0100, jfager wrote:
On Mar 31, 10:44 pm, "Rhodri James"
wrote:
[...] What
restrictions can be put on the value you get back? What can the
help system say about this, or do we have to go back to doing all
that by hand? Now translate all those questions into the
olusina eric wrote:
I hope somebody will be able to help me here.
I am trying to solve some physical problems that will require the
generation of some function in terms of some parameters. These functions
are derived from matrix operation on “characters”. Are there ways
numpy/scipy perform mat
On Thu, 02 Apr 2009 11:37:46 +1300, Lawrence D'Oliveiro wrote:
> In message <13298fc5-5024-4343-
> bf5a-7e271a08d...@o11g2000yql.googlegroups.com>, Michele Simionato
> wrote:
>
>> However, there are situations when you need thousands of lightweight
>> threads of execution ;;;
>
> The Linux kerne
Betiana Krancenblum wrote:
Hi,
I'm looking for statistical information about where Python is beeing
used as a programming language and where it is teached as a language for
beginner programmers.
Where do you think I can find that information?
There is some info at python.org.
Ask on the e
On 2009-04-01 19:12, Terry Reedy wrote:
olusina eric wrote:
I hope somebody will be able to help me here.
I am trying to solve some physical problems that will require the
generation of some function in terms of some parameters. These
functions are derived from matrix operation on “characters”.
Hi Folks,
I have a problem of handling Toplevel window. Basically, I wrote a
listbox viewer with scrollbars, and saved in file listbo.py. Then in
my main GUI window, with menu, I need to launch the listbox viewer, in
a new window. Obviously, a Toplevel window is needed. But, I failed at
passing pa
> I just mean that there should be a
> clear and easy way to do it, that it should be considered a basic
> service, and that if the best way to satisfy all the goals is to
> integrate it directly into the language, that shouldn't be shied away
> from.
Honestly, the programming language and the con
Hi,
I tried writing a small game on a pygame layer. The graphics are
fine, and at the moment, it is not graphics intensive. It is multi-
player, and for the communication, I am sending a pickle string across
a LAN, once per frame.
I'm observing some latency. It seems that socket.recv isn't
per
On Wed, 2009-04-01 at 17:58 -0700, Aaron Brady wrote:
> I tried writing a small game on a pygame layer. The graphics are
> fine, and at the moment, it is not graphics intensive. It is multi-
> player, and for the communication, I am sending a pickle string across
> a LAN, once per frame.
>
> I'm
On Apr 1, 8:28 pm, Tim Wintle wrote:
> On Wed, 2009-04-01 at 17:58 -0700, Aaron Brady wrote:
> > I tried writing a small game on a pygame layer. The graphics are
> > fine, and at the moment, it is not graphics intensive. It is multi-
> > player, and for the communication, I am sending a pickle s
On Apr 2, 6:59 am, "Rhodri James" wrote:
> On Wed, 01 Apr 2009 14:53:34 +0100, Evan wrote:
>
> > Hello -
>
> > I'm trying to decode thepcapfilewhich is packet capture by tcpdump
> > or wireshark. Is there a python module that I can use it for this
> > problem?
>
> > Can python-libpcap or pycap
Lawrence D'Oliveiro writes:
> > However, there are situations when you need thousands of lightweight
> > threads of execution ;;;
>
> The Linux kernel has been tested running hundreds of thousands of threads.
Those are still heavyweight threads requiring context switches to
switch from one to an
On Mon, 30 Mar 2009 06:40:00 -0700, jfager wrote:
> The basic idea is that a language could offer syntactic support for
> declaring configurable points in the program. The language system would
> then offer an api to allow the end user to discover a programs
> configuration service, as well as a
In message , Tim Daneliuk wrote:
> ,,, when I suggested that better open source tools existed, they kindly
> explained their complete lack of interest in moving several millions
> of lines of code to anything new.
What was their explanation?
--
http://mail.python.org/mailman/listinfo/python-list
In message <7a1dd0d8-1978-470b-
a80d-57478d7f7...@q16g2000yqg.googlegroups.com>, Paul Boddie wrote:
> And I've heard stories of "bait and
> switch" with Git: "you can do XYZ with Git but not with ..." followed
> by the discovery that you can't realistically do XYZ with Git, either.
Cite?
--
http
I've looked around for the answer and have decided to ask an expert
for the solution. Whats suppose to happen is a user pushes a button
and displays the directory content in the text edit window on the gui.
Everything works, apart from the fact that it only shows the last file
in the directory, not
Lawrence D'Oliveiro wrote:
> In message , Tim Daneliuk wrote:
>
>> ,,, when I suggested that better open source tools existed, they kindly
>> explained their complete lack of interest in moving several millions
>> of lines of code to anything new.
>
> What was their explanation?
>
Their entire
On Apr 1, 8:56 pm, CTO wrote:
> > I just mean that there should be a
> > clear and easy way to do it, that it should be considered a basic
> > service, and that if the best way to satisfy all the goals is to
> > integrate it directly into the language, that shouldn't be shied away
> > from.
>
> Ho
John Machin wrote:
On Apr 2, 2:10 am, John Posner wrote:
Dennis Lee Bieber presented a code snippet with two consecutive statements
that made me think, "I'd code this differently". So just for fun ... is
Dennis's original statement or my "_alt" statement more idiomatically
Pythonic? Are there e
Aaron Brady wrote:
My game loop looks like this:
poll events, get 1 at most
send to server
wait for server reply
render entire frame
I am very sure that commercial 'real-time' (versus turn-based)
multiplayer games do not operate that way, at least not the ones I have
played.
I suspect tha
On Wed, 1 Apr 2009, Steven D'Aprano wrote:
> On Wed, 01 Apr 2009 04:39:26 +0100, Rhodri James wrote:
> > Dragging this back to the original topic, you clearly find starting list
> > indices from zero unintuitive. To me, with a mathematical background,
> > it's not just intuitive, it's correct. Al
hi group,
my application needs to send SMS occasionally to all the clients .Is
there any library in python that supports in sending SMS.
I like to conform few information i gathered in this regard.
I can send SMS by two ways
1. Sending SMS using Email clients
2. Using sms gateway to send message
Grant Edwards wrote:
>On 2009-03-31, Dave Angel wrote:
>
>> They were added in NTFS, in the Windows 2000 timeframe, to my
>> recollection.
>
>NTFS was added in NT 3.1 (which predates Win2K by 7-8 years).
Although that's true, you didn't read his sentence. Sparse file support
was not added to N
On Apr 1, 7:06 pm, Steven D'Aprano
wrote:
> There is a major clash between the names of ordinals in human languages
> and zero-based counting. In human languages, the Nth-ordinal item comes
> in position N. You can keep that useful convention with zero-based
> counting by inventing the ugly word
On Apr 1, 10:38 pm, Terry Reedy wrote:
> Aaron Brady wrote:
>
> > My game loop looks like this:
>
> > poll events, get 1 at most
> > send to server
> > wait for server reply
> > render entire frame
>
> I am very sure that commercial 'real-time' (versus turn-based)
> multiplayer games do not operat
On Apr 1, 11:58 pm, Lie wrote:
> On Apr 1, 7:06 pm, Steven D'Aprano
>
> wrote:
> > There is a major clash between the names of ordinals in human languages
> > and zero-based counting. In human languages, the Nth-ordinal item comes
> > in position N. You can keep that useful convention with zero-b
In message <158986a9-b2d2-413e-9ca0-
c584299f1...@f1g2000prb.googlegroups.com>, 一首诗 wrote:
> On Apr 1, 4:55 pm, Lawrence D'Oliveiro central.gen.new_zealand> wrote:
>
>> In message <48506803-a6b9-432b-acef-
>>
>> b75f76e90...@v23g2000pro.googlegroups.com>, 一首诗 wrote:
>> > Until one day I find serv
On Donnerstag, 2. April 2009, Dunwitch wrote:
> for x in (fileList):
> self.ui.displayVideo.setText(x) # This only shows the last
self.ui.displayVideo.setText('\n'.join(fileList))
but I would go for a solution with QDirModel / QListView
http://doc.trolltech.com/4.5/itemview
On Apr 2, 4:05 pm, Aaron Brady wrote:
> On Apr 1, 11:58 pm, Lie wrote:
>
> > On Apr 1, 7:06 pm, Steven D'Aprano
>
> > wrote:
> > > There is a major clash between the names of ordinals in human languages
> > > and zero-based counting. In human languages, the Nth-ordinal item comes
> > > in positi
On Thu, 02 Apr 2009 18:47:29 +1300, Lawrence D'Oliveiro wrote:
>>> The question is not how many lines or how many methods, but whether it
>>> makes sense to remain as one piece or not. In one previous project, I
>>> had one source file with nearly 15,000 lines in it. Did it make sense
>>> to split
On Thu, 02 Apr 2009 04:23:32 +, John O'Hagan wrote:
> Beyond being part of a conventionally-ordered set of keys, what can an
> ordinality of zero actually mean? (That's a sincere question.)
In set theory, you start by defining the integers like this:
0 is the cardinality (size) of the empty
On Wed, 01 Apr 2009 21:58:47 -0700, Lie wrote:
> On Apr 1, 7:06 pm, Steven D'Aprano
> wrote:
>
>> There is a major clash between the names of ordinals in human languages
>> and zero-based counting. In human languages, the Nth-ordinal item comes
>> in position N. You can keep that useful conventi
Thanks Andrew. I was also of the same view that perl handled this via some
special cases.
On Wed, Apr 1, 2009 at 8:32 PM, andrew cooke wrote:
>
> more exactly, my guess is perl has a special case for this that avoids
> doing a search over all possible matchers via the pushdown stack.
>
> andrew
On Apr 1, 9:23 pm, John O'Hagan wrote:
> Despite being thoroughly acclimatised to zero-based indexing and having no
> wish to change it, I'm starting to see the OP's point.
>
> Many of the arguments presented in this thread in favour of zero-based
> indexing have rather been arguments for half-ope
On Apr 2, 1:29 am, Steven D'Aprano
wrote:
> On Wed, 01 Apr 2009 21:58:47 -0700, Lie wrote:
> > On Apr 1, 7:06 pm, Steven D'Aprano
> > wrote:
>
> >> There is a major clash between the names of ordinals in human languages
> >> and zero-based counting. In human languages, the Nth-ordinal item comes
101 - 151 of 151 matches
Mail list logo