[EMAIL PROTECTED] wrote:
> Pass your script to Perl via standard input:
> echo "print 'Hello, world'" | perl -
$ echo "print 'hello, world'" | python -
hello, world
Cheers,
--
george
--
http://mail.python.org/mailman/listinfo/python-list
Bengt Richter wrote:
[name for dec,name in sorted((int(nm.split('.')[1]),nm) for nm in namelist)]
>
> ['test.1', 'test.2', 'test.3', 'test.4', 'test.10', 'test.15', 'test.20']
Giving a key argument to sorted will make it simpler::
>>> sorted(namelist, key=lambda x:int(x.rsplit('.')[-1]))
--
Kongulo(google crawling tool) seems to be using your App, py2exe.
Great work, Thomas!
Thomas Heller wrote:
> Jeremy Jones <[EMAIL PROTECTED]> writes:
>
>
>>I've got a couple of new articles on ONLamp:
>>
>>Writing Google Desktop Search Plugins
>>http://www.onlamp.com/pub/a/python/2005/06/01/kong
PyTJ wrote:
> I need to convert a Japanese Shift-JIS CSV file to Unicode UTF-8.
>
> My machine is a Windows 98 english computer with Python 2.3.4
>
> Any hints?.
>
First, you need to install codecs to support japanese encodings.
Python 2.3.* does not support SJIS by default.
I'll give you two
praba kar wrote:
>In Php we can print RFC 2822 formatted date by
> date('r') with parameter r. Then it will print the
> below format date.
> "Thu, 7 Apr 2005 01:46:36 -0300".
> I want to print same RFC 2822 format in python. Is it
> possible in python? . If possible kindly mention the
Isaac Rodriguez wrote:
> Python is a dynamically typed language, which makes me think of the
> importance of documenting not only the purpose of a particular
function or
> class method, but also what requirements should be met by the
objects passed
> as parameters, what will the function retu
Harlin Seritt wrote:
> {1:1} Random text here. {1:2} More text here. and so on.
>
> Of course the {*} can be of any length, so I can't just do .split()
> based on the length of the bracket text. What I would like to do is to
> .split() using something akin to this:
>
> textdata.split('{*}') # The
Rakesh wrote:
> To quote a much smaller trimmed-down example, here is how it looks
> like:
> ## ---
> # Entry Point to the whole program
> ## ---
> def main():
> mylist = GenerateList()
> minnumber = min
Jive Dadson wrote:
I've got some code that compiles some text and then executes it. When
the string is "print 'Hello'", it prints "Hello". I get no exception
when I compile and execute "foo = 555". If I then compile and exec
"print foo", I get a name error. The variable foo is undefined. My
assu
alexrait1 wrote:
I use popen.popen2 or popen.popen3 to start a new process and read from
it's stdout/ write to it's stdin.
But I need a way to know when a process terminates.
Do you know about a library that provides these tools other then the
standard os module... or should I use it otherwise?
po
10 matches
Mail list logo