(Please don't top-post -- fixed)
Kevin Feng wrote:
>
>
> On 3/14/06 2:12 AM, in article [EMAIL PROTECTED],
> "Gregor Horvath" <[EMAIL PROTECTED]> wrote:
>
>
>>Kevin Feng schrieb:
>>
>>
>>>More information about this error may be available in the server error log.
>>>
>>>
>>>
>>>Any suggestion
No idea, I do not have permission to access the error log.
On 3/14/06 2:12 AM, in article [EMAIL PROTECTED],
"Gregor Horvath" <[EMAIL PROTECTED]> wrote:
> Kevin Feng schrieb:
>
>> More information about this error may be available in the server error log.
>>
>>
>>
>> Any suggestions? Much
Thanks for the pointer to dejagnu, although it is not what I was after.
The question came about because I was scripting an interface to an
electronics design automation tool that comes with a TCL interface.
I was using a companion perl script called from the TCL to do most of
the more complex chec
Don't know of a Python module (although this doesn't look complex enough for a
package anyway...), but
kpp9c wrote:
> P.S. Does any one know first of all whether these are called markov
> tables, transition tables or probability tables? I am not sure i am
> referring to this correctly and what the
Kevin Feng schrieb:
> More information about this error may be available in the server error log.
>
>
>
> Any suggestions? Much thanks.
>
What does the error log of the webserver say?
--
Greg
--
http://mail.python.org/mailman/listinfo/python-list
Title: Basic python help
I have the following simple html file that is trying to send data to a python script, however, I am getting a weird server error:
This is my HTML:
Ticker 1
This is my Python:
#!/usr/bin/python
import cgi
print "Content-type: text/html"
print
form = cgi.Fi
Icon is a language that share some similarities with Python:
http://www.cs.arizona.edu/icon/
During the execution of a Icon script there are ways to visualize the
memory:
http://www.cs.arizona.edu/icon/progvis/memmon/memmon.htm
Related pages:
http://www.cs.arizona.edu/icon/progvis/workshop/worksh
hi
i have to run a java program inside my python script.
i have some java classes declared:
os.environ['CLASSPATH'] = "blah path"
then i used the os.system method to invoke the java program and using
ret = os.WEXITSTATUS(os.system(cmd)) to catch the return
Java gave me an error about unable to l
[robert]
> In very rare cases a program crashes (hard to reproduce) :
>
> * several threads work on an object tree with dict's etc. in it. Items
> are added, deleted, iteration over .keys() ... ). The threads are "good"
> in such terms, that this core data structure is changed only by atomic
> oper
[EMAIL PROTECTED] wrote:
> I'm having a scoping problem. I have a module called SpecialFile,
> which defines:
>
> def open(fname, mode):
> return SpecialFile(fname, mode)
>
> class SpecialFile:
>
> def __init__(self, fname, mode):
> self.f = open(fname, mode)
> ...
>
[snip]
>
> Ho
I'm having a scoping problem. I have a module called SpecialFile,
which defines:
def open(fname, mode):
return SpecialFile(fname, mode)
class SpecialFile:
def __init__(self, fname, mode):
self.f = open(fname, mode)
...
The problem, if it isn't obvioius, is that the open() call in
On Tue, 14 Mar 2006, Tony Houghton <[EMAIL PROTECTED]>
wrote:-
>In any case, it does imply that timeval can be relied on to be 2 *
>32-bits (2 * long) in 32-bit architectures and something else in 64-bit
>architectures - where long is 64-bit.
Using the source below for a quick test on both a 32
markov query
I have noticed a couple markov implementations in python, but none
quite seem to do what i would like. Most seem to do an analysis of some
text and create a new text based on that... I think, (sorry i just
don't know terminology well) a markov table (or is it called a
transition table
we can do it with 'who' in *nuix, but os.getlogin() returns only the
user of the current process...
how to do it by python, any suggestions?
Best Regards.
--
http://mail.python.org/mailman/listinfo/python-list
Marc 'BlackJack' Rintsch <[EMAIL PROTECTED]> wrote:
> In <[EMAIL PROTECTED]>, robert wrote:
>
> > * Ruby without refcounts provides no deterministic __del__ in
> > non-circular refs ==> your type finally finally finally .close .close
> > .close all the time
>
> Which is what you should type in
"Michael Tobis" <[EMAIL PROTECTED]> wrote:
>While the new one is much better than the old website, the logo strikes
>me as awful.
I personally believe the new logo is miles better than the old one.
Whether you see snakes or a plus-sign or a yin-yang, it has a nice
harmonious look that still captu
[robert]
> That queue/passing-through-only-an-extra-global-var communication is
> acceptable for thin thread interaction.
> ( hope this extra global var is thread-safe in future Python's :-) )
>
> But "real" thread-programming should also be possible in Python - and it
> is with the usual disciplin
In <[EMAIL PROTECTED]>,
Big and Blue <[EMAIL PROTECTED]> wrote:
> Big and Blue wrote:
> > Tony Houghton wrote:
> >>
> >> How safe would I be assuming that
> >> sizeof(struct timeval) == 2 * sizeof(long)
> >>
> >> is always true on Linux on different architectures?
> >
> >Based on what I wa
In <[EMAIL PROTECTED]>,
Big and Blue <[EMAIL PROTECTED]> wrote:
> Tony Houghton wrote:
>>
>> How safe would I be assuming that
>>
>> sizeof(struct timeval) == 2 * sizeof(long)
>>
>> is always true on Linux on different architectures?
>
> Based on what I was looking at today (well, yes
I have following two classes
Code:
## file_A.py
class A(object):
## a contains is instances of A
a= [ ] def __init__(self, node):
self.nodes_in_A = []
self.nodes_in_A.append(node) packet_queue = [ ] ...etc
## file_B.py
import A
class B(object):
## n contains instances of B
On 12 Mar 2006 17:58:43 -0800
[EMAIL PROTECTED] wrote:
> Double-underscore methods are rewritten with the class
> name? That's an ugly hack, but remember I'm coming from
> Perl. If the language doesn't pull many other hijinks,
> that's OK.
This is GvR's way of saying "do not use double-underscore
On Mon, 13 Mar 2006 17:18:16 +0100
"Martin P. Hellwig" <[EMAIL PROTECTED]> wrote:
> While I was reading PEP 8 I came across this part:
>
> """
> Function and method arguments
> Always use 'self' for the first argument to instance
> methods. Always use 'cls' for the first argument to
>
Big and Blue wrote:
> Tony Houghton wrote:
>>
>> How safe would I be assuming that
>> sizeof(struct timeval) == 2 * sizeof(long)
>>
>> is always true on Linux on different architectures?
>
>Based on what I was looking at today (well, yesterday now), you might
> be wrong.
Howev
Tony Houghton wrote:
>
> How safe would I be assuming that
>
> sizeof(struct timeval) == 2 * sizeof(long)
>
> is always true on Linux on different architectures?
Based on what I was looking at today (well, yesterday now), you might
be wrong.
I do know that the size of a struct u
John Savage wrote:
> Could
> someone please explain the rationale behind python designers' thinking
> in deciding the function "range(1,12)" should return the sequence 1 to
> 11 rather than the more intuitively-useful 1 to 12??
There are several ways to do this, closed intervals, half-open
interva
Hi, I am now using minidom for my current development. I use cloneNode
method in Element object, but it just does not work. The test code is
very simple as follows:
=CODE==
from xml.dom.minidom import *
a=Element('see')
print a.toprettyxml()
b=a.cloneNode(True)
print b.toprett
I'm writing a python program which reads input device events so it needs
to know sizeof(struct timeval). By using the struct module I should be
able to work out sizeof(long) from python, but I can't think of a way to
measure non-fundamental types without including a little bit of C,
which I'd rathe
fumanchu wrote:
> If you used a Queue, it wouldn't be the container itself; rather, it
> would be a gatekeeper between the container and consumer code. A
> minimal example of user-side code would be:
>
> class Request:
> def __init__(self, op, data):
> self.op = op
> self.data
Sakcee wrote:
> now in package.module.checkID function, i wnat to know what is the ID
> defiend in the calling scriipt
It's almost always a really bad idea to kludge scopes like this. If
you need to access a variable from the caller's scope in a module
function, make it an argument to that functi
On 3/14/06, John Savage <[EMAIL PROTECTED]> wrote:
I've very new to python, and am currently toying with pythonD. Couldsomeone please explain the rationale behind python designers' thinkingin deciding the function "range(1,12)" should return the sequence 1 to
11 rather than the more intuitively-use
On Sun, 12 Mar 2006 21:50:32 +0800
"Keith" <[EMAIL PROTECTED]> wrote:
> So lets say have two modules.. moduleA and moduleB. they
> are both imported into a main python program using the
> "from module import *" command. now moduleA has a dynamic
> command that needs to access a command that is in m
John Savage wrote:
> Could someone please explain the rationale behind python designers' thinking
> in deciding the function "range(1,12)" should return the sequence 1 to
> 11 rather than the more intuitively-useful 1 to 12??
Essentially, it has to do with the decision to have range(5) mean the
lis
Hi
I have a script e.g.
import package.module
ID = "55"
package.module.checkID()
now in package.module.checkID function, i wnat to know what is the ID
defiend in the calling scriipt
if I dot globals(), it returns only items in module. is there a way
to get the script level namesapce
th
Fabiano Sidler wrote:
> 2006/3/12, Fabiano Sidler <[EMAIL PROTECTED]>:
>
>>Is there any way to use anonymous memory mapping in python, versions
>>earlier than 2.5?
>
> No idea or no way to do it?
Often when there's no reply for a while, it's because the question is
unclear. Rather than just ap
I've very new to python, and am currently toying with pythonD. Could
someone please explain the rationale behind python designers' thinking
in deciding the function "range(1,12)" should return the sequence 1 to
11 rather than the more intuitively-useful 1 to 12??
After downloading the substantial
Wow, thanks for all the reponses. Very helpful!
--
http://mail.python.org/mailman/listinfo/python-list
> Trent> Do you have any profile information for where in the logging
> Trent> package the time is being spent?
>
> Looking back at a recent run from a few days ago Formatter.formatTime()
> seems to be a current problem.
As Kent suggested, don't use %(asctime)s if you don't want fancy time
for
Jarek Zgoda wrote:
> How do I get a list of localized month names for current locale? The
> first thing that came to my mind was an ugly hack:
>>> import locale
>>> locale.nl_langinfo(locale.MON_1)
'January'
--
Benji York
--
http://mail.python.org/mailman/listinfo/python-list
Robert Dodier wrote:
> I've decided it's easier for me just to search for FOO, and then
> break up the string based on the locations of FOO.
>
> But I'd like to better understand regular expressions.
Those who cannot learn regular expressions are doomed to repeat string
searches. Which is not su
I'm trying to build python 2.4.2 on AIX 5.3 with the IBM xlC compiler
as per the notes in the AIX Readme file. Basically my make fails with
the errors listed below.
I'm calling configure with:
./configure --with-gcc="xlc_r -q64" --with-cxx="xlC_r -q64"
--disable-ipv6 AR="ar -X64"
It looks like
Jarek Zgoda wrote:
> How do I get a list of localized month names for current locale? The
> first thing that came to my mind was an ugly hack:
>
> import datetime
> for i in range(12):
> # as I remember, all months in 2005 had 1st in days
> datetime.date(2005, i + 1, 1).strftime('%B')
doe
> What features exactly does it not have?
Come to think of it, the only exception is probably that PyScripter (AFAIK)
does not provide conditional pause.
But I really like it. PyScripter is written in Delphi, my other favorite
language :)
-Dag
--
http://mail.python.org/mailman/listinfo/pytho
On 2006-03-13, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> Hello again,
> I am disappointed.
Yea, life's like that.
Sucks, eh?
--
Grant Edwards grante Yow! ... The waitress's
at UNIFORM sheds TARTAR SAUCE
"gregarican" <[EMAIL PROTECTED]> writes:
> reversed(a_string) (python)
>
> Which version of Python offers this function? It doesn't seem to be
> available in the 2.3 version I have installed...
>
I think it's new in 2.4.
--
http://mail.python.org/mailman/listinfo/python-list
How do I get a list of localized month names for current locale? The
first thing that came to my mind was an ugly hack:
import datetime
for i in range(12):
# as I remember, all months in 2005 had 1st in days
datetime.date(2005, i + 1, 1).strftime('%B')
but I am sure there is a better way.
[EMAIL PROTECTED] wrote:
> I agree to a certain extent, but by analogy
>
>
> ]>
>
>
> is a valid SGML/XML document and their is a lot of (superficial?)
> similarity between DTD content models and REs.
they're related, but they don't have the same semantics (Python uses
a backtracking engine, w
[EMAIL PROTECTED] wrote:
> I don't want a better way, i just want a solution to the problem as
> described!
any special reason you cannot use Python to write Python programs,
instead of demanding that someone else wastes time inventing a non-
portable solution to a braindead problem?
what's wron
Diez, Scott, and Bruno,
I thank you all for your help and suggestions. I wasn't aware that
default values were considered class (static) values. That seems a
little odd to me, but as long as I know that's the case, I'll be fine.
I initialized my list member in the __init__() method and all is
wor
In <[EMAIL PROTECTED]>, robert wrote:
> * Ruby without refcounts provides no deterministic __del__ in
> non-circular refs ==> your type finally finally finally .close .close
> .close all the time
Which is what you should type in Python too as there's no guarantee that
`__del__()` will be calle
[EMAIL PROTECTED] writes:
> I don't want a better way, i just want a solution to the problem as
> described!
I once did something like:
try:
raise ValueError
except ValueError, e:
pass
then get the traceback object out of e, and snarf the relevant source
line as mentioned before.
--
Hi Kent,
My intention is to be able to retrieve any line of code in a running
program, in the following way:
def magic_funct(s):
for line in file(s.gi_frame.f_code.co_filename):
print line
magic_funct(i for i in [1,2,3])
I just find it stupid to be obliged to use a generato
[EMAIL PROTECTED] wrote:
> Hello again,
> I am disappointed. You are the experts, you've got to try harder ;-)
> What i want is a generalisation of this tiny function:
Why? Maybe we can find a better way...
Kent
--
http://mail.python.org/mailman/listinfo/python-list
ahart a écrit :
> I'm pretty new to python and am trying to write a fairly small
> application to learn more about the language. I'm noticing some
> unexpected behavior in using lists in some classes to hold child
> objects. Here is some abbreviated code to help me explain.
>
> ###
Well, there's OpenLaszlo, which handles the sounds/animation for
http:www.pandora.com, I understand. It may be overkill for a desktop
app, but it's free. It was originally written in Python, I think, but
it uses ECMAScript for scripting.
It's free, and reportedly handles sounds and animations, and
Michal Kwiatkowski <[EMAIL PROTECTED]> writes:
[...]
> "Return a property attribute for new-style classes". After reading a bit
> about descriptors I've just assumed that property is a handy way to
> create (any) descriptors. Learning that it only creates overriding
> descriptors was a bit shocking
ahart wrote:
> I'm pretty new to python and am trying to write a fairly small
> application to learn more about the language. I'm noticing some
> unexpected behavior in using lists in some classes to hold child
> objects. Here is some abbreviated code to help me explain.
>
> When I run this script
Hello again,
I am disappointed. You are the experts, you've got to try harder ;-)
What i want is a generalisation of this tiny function:
import tokenize
import token
def magic_function(s):
readline = open(s.gi_frame.f_code.co_filename).readline
for t in
tokenize.generate_tokens(open
2006/3/12, Fabiano Sidler <[EMAIL PROTECTED]>:
> Is there any way to use anonymous memory mapping in python, versions
> earlier than 2.5?
No idea or no way to do it?
Greetings,
F. Sidler
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] wrote:
> I am running Mac OS X. I have Tcl/Tk installed. I can run the Aqua
> version (TkAqua) of wish by typing 'wish' at a terminal prompt. I can
> run the X11 version (TkX11) of wish by typing 'wish8.4-X11' in an
> x-term. If I run python and import Tkinter it always grabs
>
> Apparently, the p1 instance somehow thinks that the i3 instance is in
> its list. The i3 instance should instead be in the list for p2. By the
> way, when I call the __str__() method of p2, I get the same results as
> when I do it for p1. The list appears to be acting as if it were a
> static
Wow! Thanks everyone. Such coherent and philisophical answers. I will
read them all over on a lazy sunday as this type ethereal stuff hurts
my head after about 30 seconds. All the gurus on the python list are so
friggin' smart. This should improve my coding after I digest it all.
Thanks Again!
Der
BWill wrote:
> and ixnay on the ubyray or else I'll tell you where to stick your
> endblock delimiter :P
Umm,
Did you mean to write the above?
What has it to do with Ruby?
--
http://mail.python.org/mailman/listinfo/python-list
I'm pretty new to python and am trying to write a fairly small
application to learn more about the language. I'm noticing some
unexpected behavior in using lists in some classes to hold child
objects. Here is some abbreviated code to help me explain.
class Item
> Python closures are apparently very poor, but from what I can surmise
> of the PyGTK2 page, instances of objects are dynamic enough to add new
> methods, so you get your callbacks, at least.
It's true that Python's "lambda" is somewhat limited, but this is
rarely a problem because you can define
i'm pretty much a newbie, too, and have been dabbling with some gui
tools
so far, i like pythoncard pretty well
it wraps wxpython and seems to be pretty easy to use
--
http://mail.python.org/mailman/listinfo/python-list
Paul Rubin wrote:
> "Paul Boddie" <[EMAIL PROTECTED]> writes:
> > What people don't usually understand (or rather complain about loudly)
> > is that Trolltech can refuse to license Qt to you under the commercial
> > licence, as is their right as the owner of the copyrighted work.
>
> What is the de
Paul Rubin wrote:
> Darn, yes, that's the second time in the past couple weeks I've made
> that exact same error in a clpy post. So what's the most concise way
> of turning it back into a string? ''.join(list(reversed(a_string))) ?
> Bleccch.
Use Ruby:
print "A String".reverse
Just kidding :
Since you are comfortable with HTML, you could use the browser as your
GUI, and use a lightweight python server like Karrigell (or CherryPy,
or Turbogears) to serve the pages. A little javascript to move the
highlighting around, and . . .
Well, frankly, it's still harder than it ought to be. (I ag
On 2006-03-13, Math <[EMAIL PROTECTED]> wrote:
> Does anybody know what I have to do to run only 1 instance of
> my Python Application?
Yes.
http://www.google.com/search?hl=en&q=python+single+application+instance
On Unix, one creates a lock file. Typically
/var/run/.pid if you want a single sy
Robert Dodier wrote:
> Hello all,
>
> I'm trying to find substrings that look like 'FOO blah blah blah'
> in a string. For example give 'blah FOO blah1a blah1b FOO blah2
> FOO blah3a blah3b blah3b' I want to get three substrings,
> 'FOO blah1a blah1b', 'FOO blah2', and 'FOO blah3a blah3b blah3b'.
Paul Rubin wrote:
> So what's the most concise way
> of turning it back into a string? ''.join(list(reversed(a_string))) ?
You don't need the list(), join() can take an iterator:
''.join(reversed(a_string))
Kent
--
http://mail.python.org/mailman/listinfo/python-list
1. Try os.popen:
>>> import os
>>> os.popen('echo Hello World').read()
'Hello World\n'
2. Try a test environment built for testing shell commands, such as
DejaGnu:
http://www.gnu.org/software/dejagnu/
--
http://mail.python.org/mailman/listinfo/python-list
[EMAIL PROTECTED] schrieb:
>> Install python using fink, and invoke that. Should work against X11 for
>> all GUI-Toolkits.
>
> I prefer not to do this. Darwin is already a Unix, and Apple provides
> a version of X11 that works well with it.
> Fink seems like an
> unecessary layer that I would r
"robert" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
Though mostly ignorant of threading issues, I wonder if the following would
work. Derive a class from dict. Define a backup method that sets and
unsets a private self.lock. Define setitem and delitem methods that wrap
cal
Martin P. Hellwig wrote:
> While I was reading PEP 8 I came across this part:
>
> """
> Function and method arguments
>Always use 'self' for the first argument to instance methods.
>Always use 'cls' for the first argument to class methods.
> """
>
> Now I'm rather new to programming and u
Hi
Being a Delphi user at work, I know what you mean :)
The best python IDE I have found is Stani's Python Editor (SPE), and I
think Stani himself replied to your message as well.
It integrates wxGlade, which is nice for form-building, although I don't
really do much of that with the python co
Peter Otten <[EMAIL PROTECTED]> writes:
> >>> print reversed("abba")
>
Darn, yes, that's the second time in the past couple weeks I've made
that exact same error in a clpy post. So what's the most concise way
of turning it back into a string? ''.join(list(reversed(a_string))) ?
Bleccch.
--
htt
On Monday 13 March 2006 18:31, Math wrote:
> Does anybody know what I have to do to run only 1 instance of my Python
> Application?
> How do I check if I'm running more instances of a Application?
I would use lockfiles for that purpose. Like this:
http://aspn.activestate.com/ASPN/Cookbook/Python/R
Robert Dodier wrote:
> Hello all,
>
> I'm trying to find substrings that look like 'FOO blah blah blah'
> in a string. For example give 'blah FOO blah1a blah1b FOO blah2
> FOO blah3a blah3b blah3b' I want to get three substrings,
> 'FOO blah1a blah1b', 'FOO blah2', and 'FOO blah3a blah3b blah3b'.
On 13 Mar 2006 10:19:05 -0800, Paul Rubin
<"http://phr.cx"@nospam.invalid> wrote:
> "Paul Boddie" <[EMAIL PROTECTED]> writes:
> > What people don't usually understand (or rather complain about loudly)
> > is that Trolltech can refuse to license Qt to you under the commercial
> > licence, as is thei
Paul Rubin wrote:
> "gregarican" <[EMAIL PROTECTED]> writes:
>> > reversed(a_string) (python)
>>
>> Which version of Python offers this function? It doesn't seem to be
>> available in the 2.3 version I have installed...
>
> I think it's new in 2.4.
Needs a little help, though:
>>> print re
Hello,
Pardon my English...
Does anybody know what I have to do to run only 1 instance of my Python
Application?
How do I check if I'm running more instances of a Application?
Thank you all
--
http://mail.python.org/mailman/listinfo/python-list
Ravi Teja wrote:
> I do not think that technology has gone backwards. Hyper card
> alternatives still exist.
> http://www.metacard.com/
At $995 per seat it's not likely to be used for a home project.
Kent
--
http://mail.python.org/mailman/listinfo/python-list
Doh, I am indeed referring to the standard "cmd" module - thanks!
To [EMAIL PROTECTED], the above module does what you describe.
Thanks again,
David.
--
http://mail.python.org/mailman/listinfo/python-list
Skipper wrote:
> I can not believe that there isn't a GUI programing tool that will
> allow me to build GUI apps - just like I use Dreamweaver to build a
> web page ... a WYSIWYG builder that does a few simplet things and
> calls other programs ...
>
> Oh well no silver bullet!
If you are int
Well that definitly works, thanks. Is there any way to keep the themes
though?
--
http://mail.python.org/mailman/listinfo/python-list
"Paul Boddie" <[EMAIL PROTECTED]> writes:
> What people don't usually understand (or rather complain about loudly)
> is that Trolltech can refuse to license Qt to you under the commercial
> licence, as is their right as the owner of the copyrighted work.
What is the deal here? Why would they refu
Hi
I don't think this is what you want (a string representation of the
argument passed to a function as that argument is at runtime is way
beyond my abilities), but this can retrieve the literal text in the
function call as it appears in the .py file, assuming you have the .py
file available a
<[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Hi
>
> I wonder if Python is capable of the following: define a function which
> returns its argument.
> I mean:
> def magic_function(arg):
>.. some magic code ...
>
> that behaves the following way:
>
> assert magic_functi
Thomas Guettler wrote:
>
> Have you read all the text?
>
> """
> Two qualities of the Qt Commercial License should be emphasized:
>
> You need it before you start development of proprietary software.
>
> You must purchase a Qt Commercial License from Trolltech or from any of
> its authorized resell
Dennis Lee Bieber wrote:
> The Amiga did have a means for such... It differentiated between
> local and global environment variables. Locals were kept in a process
> memory structure and behaved as they do on most other OSs... Globals,
> however, were short files maintained in ENV: (a logical name
"gregarican" <[EMAIL PROTECTED]> writes:
> > reversed(a_string) (python)
>
> Which version of Python offers this function? It doesn't seem to be
> available in the 2.3 version I have installed...
I think it's new in 2.4.
--
http://mail.python.org/mailman/listinfo/python-list
Paul Rubin wrote:
> reversed(a_string) (python)
Which version of Python offers this function? It doesn't seem to be
available in the 2.3 version I have installed...
--
http://mail.python.org/mailman/listinfo/python-list
Hello all,
I'm trying to find substrings that look like 'FOO blah blah blah'
in a string. For example give 'blah FOO blah1a blah1b FOO blah2
FOO blah3a blah3b blah3b' I want to get three substrings,
'FOO blah1a blah1b', 'FOO blah2', and 'FOO blah3a blah3b blah3b'.
I've tried numerous variations o
rtilley <[EMAIL PROTECTED]> writes:
> a_string.reverse (ruby)
> a_string[::-1](python)
reversed(a_string) (python)
--
http://mail.python.org/mailman/listinfo/python-list
In article <[EMAIL PROTECTED]>,
[EMAIL PROTECTED] wrote:
> Hi
>
> I wonder if Python is capable of the following: define a function which
> returns its argument.
> I mean:
> def magic_function(arg):
> .. some magic code ...
>
> that behaves the following way:
>
> assert magic_funct
Kay Schluehr wrote:
> Storing arguments away before they are evaluated doesn't work in
> Python. You have to hack the compiler in order to access the parsetree.
> You might take a look at the compiler package of the standard library
> that enables access to ASTs. Thus you could define lazy evaluat
BWill wrote:
> and ixnay on the ubyray or else I'll tell you where to stick your
> endblock delimiter :P
OK, I can't help it... which is more readable:
a_string.reverse(ruby)
a_string[::-1] (python)
--
http://mail.python.org/mailman/listinfo/python-list
Hell, this sounds interesting. Do you mean like matching commands when
they are not yet complete, like
sh tech
instead of:
show tech-support
?
--
http://mail.python.org/mailman/listinfo/python-list
In order to facilitate small groups
working on specific Python-in-Education projects, we have launched an
edupython list on google groups(http://groups.google.com/group/edupython
or [EMAIL PROTECTED]).
We envision participation by people trying to coordinate work on the
nuts and bolts implementati
1 - 100 of 178 matches
Mail list logo