Hello,
In terms of in-code documentation of function / section headers, change logs,
etc. Are there well-done sample files I can use as inspiration?
Thank you,
:)
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listi
On Sun, May 31, 2009 at 5:35 PM, Michael H. Goldwasser wrote:
>
> Yesterday, I posted a question to python-list involving custom
> deepcopies in an inheritance hierarchy. I haven't received any
> responses, so I thought I'd cross-post to see if anyone on tutor
> has any thoughts.
>
> To avoid spl
Yesterday, I posted a question to python-list involving custom
deepcopies in an inheritance hierarchy. I haven't received any
responses, so I thought I'd cross-post to see if anyone on tutor
has any thoughts.
To avoid splitting the thread, I'll simply reference the original post at
http://mail.p
"David" wrote
OK, this is what I came up with, how else could I do it so as not to use
sys.exit() ?
You don;t need the exit(), The program will just drop off the end
silently without it. Thre are several other redundant bits you could
just miss out:
class FertRate:
def __init__(self,
W W wrote:
One thing that's probably not in the scope of the program but really
usually a good idea is error checking.
i.e. this line:
rate = float(raw_input("Enter rate i.e. (0.5) : "))
could be converted to something like:
try:
rate = float(raw_input("Enter rate..."))
except ValueErr
2009/5/31 Nick Burgess :
> Got it.
>
> the row is not a string or buffer but the cell is..
>
> for row in spamReader:
> for cell in row:
> if pattern.search(cell):
> print ', '.join(row)
>
>
Alternatively, if you know that the string you want to search for only
appears in a sin
Got it.
the row is not a string or buffer but the cell is..
for row in spamReader:
for cell in row:
if pattern.search(cell):
print ', '.join(row)
On Sun, May 31, 2009 at 5:09 AM, Nick Burgess wrote:
> Thank you for your response and my apologies for the non-useful
> out
Thank you for your response and my apologies for the non-useful
output. After searching again this task has been done by
pyExcelerator, the tool xls2csv-gerry.py does this great. I am now
trying to parse through the csv's and return the rows containing the
matching strings. Python is looking for
ALAN GAULD wrote:
but I get an error here;
def main():
frate = FertRate(get_inputs())
File "./fert_class.py", line 15, in main
frate = FertRate(get_inputs())
TypeError: __init__() takes exactly 5 arguments (2 given)
Sorry my mistake. Because get_inputs() returns a tuple
you h
"Nick Burgess" wrote
I am trying to make this code work. I don't have any experience with
defining things and this is my second program. The error returmed is
"SyntaxError: invalid syntax"
Please post the whole error message, much of the useful stufff - like
the location of the problem!
"xbmuncher" wrote
I'd like to use notepad++ to execute the scripts I edit, is there a way
to
solve this problem?
Thats really a question for Notepad++ users!
You might be able to use a shortcut to Notepad++ and change
that Startup folder to be the one where your python scripts live?
Beyond
11 matches
Mail list logo