2014年6月12日木曜日 14時43分42秒 UTC+9 Steven D'Aprano:
> On Wed, 11 Jun 2014 21:56:06 -0700, hito koto wrote:
>
>
>
> > I want to use while statement,
>
> >
>
> > for example:
>
> def foo(x):
>
> > ... y = []
>
> > ... while x !=[]:
>
> > ... y.append(x.pop())
>
> > ...
On Wed, 11 Jun 2014 21:56:06 -0700, hito koto wrote:
> I want to use while statement,
>
> for example:
def foo(x):
> ... y = []
> ... while x !=[]:
> ... y.append(x.pop())
> ... return y
> ...
print foo(a)
> [[10], [5, 6, 7, 8, 9], [1, 2, 3, 4]]
a
> [] but thi
On Thu, Jun 12, 2014 at 2:56 PM, hito koto wrote:
> I want to use while statement,
This sounds like homework. Go back to your teacher/tutor for
assistance, rather than asking us to do the work for you; or at very
least, word your question in such a way that we can help you to learn,
rather than j
2014年6月12日木曜日 12時58分27秒 UTC+9 Chris Angelico:
> On Thu, Jun 12, 2014 at 1:40 PM, Vincent Vande Vyvre
>
> wrote:
>
> > Le 12/06/2014 05:12, hito koto a écrit :
>
> >
>
> >> Hello,all
>
> >> I'm first time,
>
> >>
>
> >> I want to make a while statement which can function the same x.pop () an
On Wednesday 11 June 2014 22:11:53 Gregory Ewing did opine
And Gene did reply:
> Steven D'Aprano wrote:
> > Automotive cooling fluid in modern sealed radiators is typically a
> > mixture of 50% anti-freeze and 50% water.
>
> Sometimes it's even more than 50%, at which point
> you really have an an
On Thu, Jun 12, 2014 at 12:08 PM, Steven D'Aprano
wrote:
> I'm just pointing out that our computational technology uses
> over a million times more energy than the theoretical minimum, and
> therefore there is a lot of room for efficiency gains without sacrificing
> computer power. I never imagine
The code available from:
http://izecksohn.com/pedro/python/canvas/testing.py
draws 2 horizontal lines on a Canvas. Why the 2 lines differ on thickness and
length?
The Canvas' method create_line turns on at least 2 pixels. But I want to turn
on many single pixels on a Canvas. How should I d
On Thu, Jun 12, 2014 at 1:40 PM, Vincent Vande Vyvre
wrote:
> Le 12/06/2014 05:12, hito koto a écrit :
>
>> Hello,all
>> I'm first time,
>>
>> I want to make a while statement which can function the same x.pop () and
>> without the use of pop、how can i to do?
>>
>> i want to change this is code:
>
Le 12/06/2014 05:12, hito koto a écrit :
Hello,all
I'm first time,
I want to make a while statement which can function the same x.pop () and
without the use of pop、how can i to do?
i want to change this is code:
def foo(x):
y = []
while x !=[]:
y.append(x.pop())
return
hito koto Wrote in message:
> Hello,all
> I'm first time,
>
> I want to make a while statement which can function the same x.pop () and
> without the use of pop、how can i to do?
No idea what the question means. Are you just trying to rewrite
the loop in a python implementation where pop is bro
Hello,all
I'm first time,
I want to make a while statement which can function the same x.pop () and
without the use of pop、how can i to do?
i want to change this is code:
def foo(x):
y = []
while x !=[]:
y.append(x.pop())
return y
--
https://mail.python.org/mailman/listinfo
Steven D'Aprano wrote:
Automotive cooling fluid in modern sealed radiators is typically a
mixture of 50% anti-freeze and 50% water.
Sometimes it's even more than 50%, at which point
you really have an antifreeze-cooled engine. :-)
--
Greg
--
https://mail.python.org/mailman/listinfo/python-list
On Wed, 11 Jun 2014 08:28:43 -0700, Rustom Mody wrote:
> Steven D'Aprano wrote:
>
>> Not the point. There's a minimum amount of energy required to flip a
>> bit. Everything beyond that is, in a sense, just wasted. You mentioned
>> this yourself in your previous post. It's a *really* tiny amount of
On Wed, 11 Jun 2014 08:48:36 -0400, Roy Smith wrote:
> In article <53984cd2$0$29988$c3e8da3$54964...@news.astraweb.com>,
> Steven D'Aprano wrote:
>
>> Yes, technically water-cooled engines are cooled by air too. The engine
>> heats a coolant (despite the name, usually not water these days) whic
> I'm writing a JIT compiler named cyjit using cython code as a backend. It
> designed primarily reference numba.jit. the jitted python function will be
> converted to cython code then compiled to c extension.
> Use decorate to specify compiled function.
> for example:
> from cyjit import jit
>
在 Jun 12, 2014,1:16,Skip Montanaro 写道:
>> You might say that but I couldn't possibly comment.
>
> You could run the message through Google Translate. It's not
> publication quality translation, but serves the needs in this
> instance. (Gmail offers to translate the OP's message for me.)
>
> H
On 6/11/2014 2:27 PM, Stefan Ram wrote:
Mark Lawrence writes:
IDLE is available on all platforms and is written in tkinter. But
personally I'd rather use the command line :)
In the meantime, I have learned that tkinter in fact has
become part of a standard Python implementations, and i
On Thu, Jun 12, 2014 at 5:39 AM, wrote:
> When presented with options, these are the possible stances:
>
> 1. (Lead) Become educated on the options and decide on one.
> 2. (Follow) Become educated on the options and remain impartial.
> 3. Remain ignorant of the similarities/differences and decide
> I'm afraid I don't understand what all that means.
>
>
>
> But I invariably go for SQL over any abstraction paradigm.
When presented with options, these are the possible stances:
1. (Lead) Become educated on the options and decide on one.
2. (Follow) Become educated on the options and remai
2014-06-11 14:23 GMT+02:00 BrJohan :
> For some genealogical purposes I consider using Python's re module.
>...
>
> Now, my problem: Is there a way to decide whether any two - or more - of
> those regular expressions will match the same string?
>
> Or, stated a little differently:
>
> Can it, for a
On 11 June 2014 13:23:14 BST, BrJohan wrote:
>For some genealogical purposes I consider using Python's re module.
>
>Rather many names can be spelled in a number of similar ways, and in
>order to match names even if they are spelled differently, I will build
>
>regular expressions, each of whic
sorry,wrong version post
发自我的 iPhone
> 在 Jun 12, 2014,0:16,mm0fmf 写道:
>
>> On 11/06/2014 10:37, 1989lzhh wrote:
>> 我正在写一个使用cython code作为后端的即时编译器名为cyjit,将python code
>> 转换为cython code再编译为c extension导入.设计上主要参考numba.jit的思路,
>> 使用decorate来指定要编译的function,例如:
>> from cyjit import jit
>> @jit('int(int
> You might say that but I couldn't possibly comment.
You could run the message through Google Translate. It's not
publication quality translation, but serves the needs in this
instance. (Gmail offers to translate the OP's message for me.)
Here's what GT produced (successfully translates the Chin
On 06/11/2014 10:35 AM, Michael Torrie wrote:
> On 06/11/2014 06:23 AM, BrJohan wrote:
>> For some genealogical purposes I consider using Python's re module.
>>
>> Rather many names can be spelled in a number of similar ways, and in
>> order to match names even if they are spelled differently, I
On 11/06/2014 10:37, 1989lzhh wrote:
我正在写一个使用cython code作为后端的即时编译器名为cyjit,将python code
转换为cython code再编译为c extension导入.设计上主要参考numba.jit的思路,
使用decorate来指定要编译的function,例如:
from cyjit import jit
@jit('int(int,int)')
def add(a,b):
return a+b
add(1,2)#compiled
@jit('int(int,int)',
locals=''
On 06/10/2014 01:43 PM, alister wrote:
> On Tue, 10 Jun 2014 12:27:26 -0700, wxjmfauth wrote:
>> BTW, very easy to explain.
Yeah he keeps saying that, but he never does explain--just flails around
and mumbles "unicode.org." Guess everyone has to have his or her
windmill to tilt at.
--
https://
On 06/11/2014 06:23 AM, BrJohan wrote:
> For some genealogical purposes I consider using Python's re module.
>
> Rather many names can be spelled in a number of similar ways, and in
> order to match names even if they are spelled differently, I will build
> regular expressions, each of which is
On Wednesday, June 11, 2014 1:11:12 PM UTC+5:30, Gregory Ewing wrote:
> Steven D'Aprano wrote:
> > Everything *eventually* gets converted to heat, but not immediately.
> > There's a big difference between a car that gets 100 miles to the gallon,
> > and one that gets 1 mile to the gallon.
> With
On 6/11/14 8:26 AM, Robert Kern wrote:
Anyways, to your new problem, yes it's possible. Search for "regular
expression intersection" for possible approaches.
I agree, I would not use a decision (decision tree) but would consider
a set of filters from most specific to least specific.
marcus
Am 11.06.2014 14:23 schrieb BrJohan:
Can it, for a pair of regular expressions be decided whether at least
one string matching both of those regular expressions, can be constructed?
If it is possible to make such a decision, then how? Anyone aware of an
algorithm for this?
Just a feeling-base
On Wed, Jun 11, 2014 at 1:19 AM, Frank Millman wrote:
> First attempt - same as before
>
> loop = asyncio.get_event_loop()
> threading.Thread(target=loop.run_forever).start()
> input('Press to stop')
> loop.stop()
> loop.close()
Each event loop is hosted by a specific thread.
On Wed, 11 Jun 2014 19:41:12 +1200, Gregory Ewing wrote:
> Steven D'Aprano wrote:
>> Everything *eventually* gets converted to heat, but not immediately.
>> There's a big difference between a car that gets 100 miles to the
>> gallon, and one that gets 1 mile to the gallon.
>
> With a car, the eng
Hi ...
So I'm not receiving more emails from Python mailing list or
posting/sending more messages ...
I'm keeping your emails that I received to contact all of you when it
will be time to step forward ...
If you want you can send me your cv or one small text to
j...@premium-sponsor.com ...
On 2014-06-11 13:23, BrJohan wrote:
For some genealogical purposes I consider using Python's re module.
Rather many names can be spelled in a number of similar ways, and in order to
match names even if they are spelled differently, I will build regular
expressions, each of which is supposed to m
In article ,
alister wrote:
> On Wed, 11 Jun 2014 00:00:49 +, Steven D'Aprano wrote:
>
> > On Wed, 11 Jun 2014 06:37:01 +1000, Chris Angelico wrote:
> >
> >> I don't know a single piece of programming advice which, if taken as an
> >> inviolate rule, doesn't at some point cause suboptimal
In article <53984cd2$0$29988$c3e8da3$54964...@news.astraweb.com>,
Steven D'Aprano wrote:
> Yes, technically water-cooled engines are cooled by air too. The engine
> heats a coolant (despite the name, usually not water these days) which
> then heats the air.
Not water??? I'm not aware of any
On Wed, 11 Jun 2014 19:50:20 +1200, Gregory Ewing wrote:
> Chris Angelico wrote:
>> So, let me get this straight. A CPU has to have a fan, but a car engine
>> doesn't, because the car's moving at a hundred kays an hour. I have a
>> suspicion the CPU fan moves air a bit slower than that.
I'm not s
For some genealogical purposes I consider using Python's re module.
Rather many names can be spelled in a number of similar ways, and in
order to match names even if they are spelled differently, I will build
regular expressions, each of which is supposed to match a number of
similar names.
alister writes:
> On Wed, 11 Jun 2014 08:29:06 +1000, Tim Delaney wrote:
> > By his own admission, jmf doesn't use Python anymore. His only
> > reason to remain on this emailing/newsgroup is to troll about the
> > FSR. Please don't reply to him (and preferably add him to your
> > killfile).
>
> I
我正在写一个使用cython code作为后端的即时编译器名为cyjit,将python code 转换为cython code再编译为c
extension导入.设计上主要参考numba.jit的思路,使用decorate来指定要编译的function,例如:
from cyjit import jit
@jit('int(int,int)')
def add(a,b):
return a+b
add(1,2)#compiled
@jit('int(int,int)',
locals='''
int c
''')
def add1(a,b):
c
On 06/11/2014 05:42 AM, Michael Torrie wrote:
On 06/10/2014 03:15 PM, Carlos Anselmo Dias wrote:
Hi...
I don't understand the 'problem' of several people ...
I created one post because I've several projects, I'm looking for one
team of experienced experts in Python to work in my projects ...
On 06/11/2014 09:34 AM, alister wrote:
On Tue, 10 Jun 2014 22:15:29 +0100, Carlos Anselmo Dias wrote:
Hi...
I don't understand the 'problem' of several people ...
I created one post because I've several projects, I'm looking for one
team of experienced experts in Python to work in my project
On Wed, 11 Jun 2014 00:00:49 +, Steven D'Aprano wrote:
> On Wed, 11 Jun 2014 06:37:01 +1000, Chris Angelico wrote:
>
>> I don't know a single piece of programming advice which, if taken as an
>> inviolate rule, doesn't at some point cause suboptimal code.
>
> "Don't try to program while your
On Tue, 10 Jun 2014 22:15:29 +0100, Carlos Anselmo Dias wrote:
> Hi...
>
> I don't understand the 'problem' of several people ...
>
> I created one post because I've several projects, I'm looking for one
> team of experienced experts in Python to work in my projects ... asap
> ... I provided one
On Wed, 11 Jun 2014 08:29:06 +1000, Tim Delaney wrote:
> On 11 June 2014 05:43, alister wrote:
>
>
>> Your error reports always seem to resolve around benchmarks despite
>> speed not being one of Pythons prime objectives
>>
>>
> By his own admission, jmf doesn't use Python anymore. His only rea
Chris Angelico wrote:
So, let me get this straight. A CPU has to have a fan, but a car
engine doesn't, because the car's moving at a hundred kays an hour. I
have a suspicion the CPU fan moves air a bit slower than that.
If the car were *always* moving at 100km/h, it probably
wouldn't need a fan
Steven D'Aprano wrote:
Everything *eventually* gets converted to heat, but not immediately.
There's a big difference between a car that gets 100 miles to the gallon,
and one that gets 1 mile to the gallon.
With a car, the engine converts some of its energy to
kinetic energy, which is subsequen
Hi all
I have a 'start.py' script that kicks off my program by starting a number of
services.
For now, I stop it by allowing the user to press , after which I
close down the services and stop the program. (For production I imagine it
would be better to run it in the background and send it some
Rustom Mody wrote:
JFTR: Information processing and (physics) energy are about as convertible
as say: "Is a kilogram smaller/greater than a mile?"
Actually, that's not true. There is a fundamental
thermodynamic limit on the minimum energy needed to
flip a bit from one state to the other, so in
49 matches
Mail list logo