May The Gods have mercy on my soul.
MiniWiki is now offered for downloading. 1.3.0 is not in presentable
condition for them what would like to kick it around some.
http://www.tinylist.org/MiniWIKI130.zip
Included in it is the zip archive for the server I settled on which is a
very nice little
"Bob Gailer" <[EMAIL PROTECTED]> wrote
> although is says 'resulting in a [sic] executable". Not sure what
> that
> means, unless the obvious - an .exe file which when run displays
> "Hello
> World!". In that case 263 bytes is remarkable.
It does and it is. That is Forth's strong point, it is
"Andrei" <[EMAIL PROTECTED]> wrote
> Alternatively, you could put the results as keys in a dictionary,
> then request
> mydict.keys() to get a list of unique outcomes.
I thought of that too, but couldn't think how to do it in a list
comprehension. It seemed like it should be possible but I
coul
"Ismael Farfán Estrada" <[EMAIL PROTECTED]> wrote
> By any chance is this your tutorial?
> http://www.freenetpages.co.uk/hp/alan.gauld
Yes that's it.
> I entered there but the parts "Writing web clients" and "Writing
> Web Applications" are dissabled
I'm writing them at the moment. :-)
But the
> -Original Message-
> Date: Fri, 02 Mar 2007 14:54:04 -0800
> From: Bob Gailer <[EMAIL PROTECTED]>
> Subject: Re: [Tutor] forth
> To: Hilton Garcia Fernandes <[EMAIL PROTECTED]>
> Cc: tutor@python.org
> Message-ID: <[EMAIL PROTECTED]>
> Content-Type: text/plain; charset=ISO-8859-1; format=
Bob,
Thanks a million
I will start talking to the other guys
Thanks
Lance
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
Lance Haig wrote:
> Bob Gailer wrote:
>> Lance Haig wrote:
>>> Hi,
>>>
>>> I am helping on an OS project called bongo-project and I am trying
>>> to debug a script that is used for migration. When I run the file I
>>> get an error. I have traced it down to a file called libs.c.
>>>
>>> I know tha
Hilton Garcia Fernandes wrote:
> in python:
>
> print "Hello world!"
>
> 21 bytes.
>
True, but the forth program is (as I read it) more equivalent to:
def helloWorld():
print "Hello World!"
although is says 'resulting in a [sic] executable". Not sure what that
means, unless the obvious -
>
>I don't think you can make it work under Linux. The Jython applet
>is your nearest option. You will be better learing the ninimum of
>JavaScript IMHO. Try my tutorial as a quickl way in, especially
>if you know Python...
>
>Finally, you may be able to do what you want using the urllib
>module to
Bob Gailer wrote:
> Lance Haig wrote:
>> Hi,
>>
>> I am helping on an OS project called bongo-project and I am trying to
>> debug a script that is used for migration. When I run the file I get
>> an error. I have traced it down to a file called libs.c.
>>
>> I know that the file looks like a c fi
Lance Haig wrote:
> Hi,
>
> I am helping on an OS project called bongo-project and I am trying to
> debug a script that is used for migration. When I run the file I get an
> error. I have traced it down to a file called libs.c.
>
> I know that the file looks like a c file but I am confused by som
Hi,
I am helping on an OS project called bongo-project and I am trying to
debug a script that is used for migration. When I run the file I get an
error. I have traced it down to a file called libs.c.
I know that the file looks like a c file but I am confused by some of
the code in it. I would
> I was playing with some simple HTTP CGI server code
> and discovered what I think may be a bug in
> CGIHTTPServer.CGIHTTPRequestHandler. A "GET" request
> without a leading '/' from a telnet session displays
> the CGI script rather than the script's output. If >
the
> request includes the leading
in python:
print "Hello world!"
21 bytes.
all the best,
hilton
Em Sexta 02 Março 2007 16:48, Kirk Bailey escreveu:
> Hello world
>
> : helloWorld ."Hello World!;
>
> that's it.
>
> HelloWorld is now part of the language. Now if your language instance
> lets you compile it down, it will includ
Hello world
: helloWorld ."Hello World!;
that's it.
HelloWorld is now part of the language. Now if your language instance
lets you compile it down, it will include all functions to create that
function, and leave all others out, resulting in a executable. Mine came
in at 263 bytes.
Microsoft
Yeppers, prolog is about as normal as a chocolate glazed neon donut.
Alan Gauld wrote:
> "Luke Paireepinart" <[EMAIL PROTECTED]> wrote
>>> forth ... while very good for small programs
>>> to imbed into controller cpu's to bury inside some machine,
>
> It's a relatively little known fact that Sun
Luke Paireepinart wrote:
> Kent Johnson wrote:
>> Luke Paireepinart wrote:
>>> Your RE is wrong.
>>> Refer to http://docs.python.org/lib/re-syntax.html
>>> * Causes the resulting RE to match 0 or more repetitions of the
>>> preceding RE, as many repetitions as are possible. ab* will match
>>> 'a'
Kent Johnson wrote:
> Luke Paireepinart wrote:
>
>> doug shawhan wrote:
>>
>>> I've been looking through various sites, but cannot find the magic
>>> button that allows me to match a string with linefeeds
>>> I'd rather not strip out the linefeeds, then stick them back in. :-)
>>>
>>> I'm
Luke Paireepinart wrote:
> doug shawhan wrote:
>> I've been looking through various sites, but cannot find the magic
>> button that allows me to match a string with linefeeds
>> I'd rather not strip out the linefeeds, then stick them back in. :-)
>>
>> I'm attempting something that should be fairl
doug shawhan wrote:
> I've been looking through various sites, but cannot find the magic
> button that allows me to match a string with linefeeds
> I'd rather not strip out the linefeeds, then stick them back in. :-)
>
> I'm attempting something that should be fairly simple:
>
> snippy = re.comp
doug shawhan wrote:
> I've been looking through various sites, but cannot find the magic
> button that allows me to match a string with linefeeds
> I'd rather not strip out the linefeeds, then stick them back in. :-)
>
> I'm attempting something that should be fairly simple:
>
> snippy = re.compil
On 3/2/07, doug shawhan <[EMAIL PROTECTED]> wrote:
> I've been looking through various sites, but cannot find the magic button
> that allows me to match a string with linefeeds
> I'd rather not strip out the linefeeds, then stick them back in. :-)
Try this:
>>> s = '''Good gravy! Hi there.
I'm so
I've been looking through various sites, but cannot find the magic button
that allows me to match a string with linefeeds
I'd rather not strip out the linefeeds, then stick them back in. :-)
I'm attempting something that should be fairly simple:
snippy = re.compile('Hi there.*Bye there.')
s = '
Andrei wrote:
>> "Smith, Jeff" medplus.com> wrote
>>
>>> In other words, applying somefun to the results of the iterator
>>> return
>>> duplicates but I want the constructed list to contain none.
>>> l = [somefun(i) for i some-iterator if somefun(i) not in l]
>>>
>>> doesn't work (not that I expe
On Mar 2, 2007, at 9:56 AM, Alan Gauld wrote:
> Why not use a Set?
>
> s = Set([somefun(i) for i in some-iterator])
>
> Might be slow for big lists though...
I'm curious why using a Set would be slower than doing it in a loop?
In either case, the processor has to scan through all the data
l
"Luke Paireepinart" <[EMAIL PROTECTED]> wrote
>
>> forth ... while very good for small programs
>> to imbed into controller cpu's to bury inside some machine,
It's a relatively little known fact that Sun use Forth as the
monitor/bootloader in their servers. When you do a shutdown
on a Sun box it
> "Smith, Jeff" medplus.com> wrote
>
> > In other words, applying somefun to the results of the iterator
> > return
> > duplicates but I want the constructed list to contain none.
>
> > l = [somefun(i) for i some-iterator if somefun(i) not in l]
> >
> > doesn't work (not that I expected it to).
Smith, Jeff wrote:
> I find a common thing to do is
>
> l = list()
> for i in some-iterator:
> if somefum(i) != list:
> l.append(somefun(i))
How about using the same condition you do in the if? Like:
l=[somefun(i) for i in some-iterator if not type(somefun(i)) is list]
HTH
Jordan
_
Barton David wrote:
> I like that I can access the contents of a zip archive that's stored
> in memory (rather than on disk) by packing the archive contents into a
> StringIO or cStringIO object and feeding that to ZipFile...
>
> i.e.
>
> filelike=cStringIO.StringIO(archive_as_string)
> zf=zi
> forth uses a dictionary to locate and execute all its functions and
> subfunctions. it is a threaded language. so it spends much of it's
> time looking up functions in the dictionary. in large programs this
> results in the majority of it's excecutiojn time being spent in the
> dictionary, a
Hi all,
I was playing with some simple HTTP CGI server code
and discovered what I think may be a bug in
CGIHTTPServer.CGIHTTPRequestHandler. A "GET" request
without a leading '/' from a telnet session displays
the CGI script rather than the script's output. If the
request includes the leading '/',
"Smith, Jeff" <[EMAIL PROTECTED]> wrote
> In other words, applying somefun to the results of the iterator
> return
> duplicates but I want the constructed list to contain none.
> l = [somefun(i) for i some-iterator if somefun(i) not in l]
>
> doesn't work (not that I expected it to).
Why not u
Hi Alan,
I had installed Python through cygwin and then installed Gdal from
source. I have tried everything but it does not work, my guess is I am
missing something trivial, I am planning to uninstall everything
(Cygwin and Gdal) and then reinstall all of it again over the weekend,
this is my last
I find a common thing to do is
l = list()
for i in some-iterator:
if somefum(i) != list:
l.append(somefun(i))
In other words, applying somefun to the results of the iterator return
duplicates but I want the constructed list to contain none.
l = [somefun(i) for i some-iterator]
will
I know that there are several ways to execute a string which represents a
piece of python code.
Out of curiosity, is it only eval which returns a value? (as below, where
the string corresponds to a defined function).
def addone(val):
... return val + 1
...
res = eval('addone(10)')
Thanks
I like that I can access the contents of a zip archive that's stored in
memory (rather than on disk) by packing the archive contents into a
StringIO or cStringIO object and feeding that to ZipFile...
i.e.
filelike=cStringIO.StringIO(archive_as_string)
zf=zipfile.ZipFile(filelike)
content=zf.re
Thanks for the update Tim.
I haven't downloaded the package in a while since
I've been using ActiveStates version on my Windows box
which includes the extensions in the bundle.
Alan g.
- Original Message
From: Tim Golden <[EMAIL PROTECTED]>
To: Alan Gauld <[EMAIL PROTECTED]>
Cc: tutor
Alan Gauld wrote:
> You can do that in Internet Explorer provided you
> a) Have the winall package installed and
Just an aid to newcomers: the "winall" package
referred to here are the windows-oriented
extension modules by Mark Hammond which used to
be known as win32all and are now known as pywin
"Dhiraj Sharma" <[EMAIL PROTECTED]> wrote
>
> p = subprocess.Popen("cat", buffer=0, stdin=subprocess.PIPE,
> stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
>
> fdata = open('input');
> for l in fdata:
> p.stdin.write(l)
> m = p.stdout.readline()
>
39 matches
Mail list logo