Matt Domeier wrote:
Hi Wayne,
Yes, that should work perfectly, but it is in writing files that I'm
having the problem. I'm still very new to python, so I only know to use
something like filename.write(str(listname)) to write my list to a file..
Is there a straightforward method of combining th
Le Sun, 26 Apr 2009 22:35:36 +0100,
Dayo Adewunmi s'exprima ainsi:
> How can I
>
> a) Open my shell, and do something like: $ python countdown.py
> but have it take an argument and pass it to the function, and execute.
When your code is (nicely) organised as a set of funcs or class definitio
On Mon, Apr 27, 2009 at 2:46 AM, A.T.Hofkamp wrote:
> you are making
> a IO-bound app, so threading doesn't buy you anything in performance and
> gives a big headache in data protection
Please explain. Presumably the single-threaded app is not IO-bound.
Adding threads can push it to the point of
Kent Johnson wrote:
On Mon, Apr 27, 2009 at 2:46 AM, A.T.Hofkamp wrote:
you are making
a IO-bound app, so threading doesn't buy you anything in performance and
gives a big headache in data protection
Please explain. Presumably the single-threaded app is not IO-bound.
Adding threads can push i
On Mon, Apr 27, 2009 at 9:29 AM, A.T.Hofkamp wrote:
> Kent Johnson wrote:
>>
>> On Mon, Apr 27, 2009 at 2:46 AM, A.T.Hofkamp wrote:
>>>
>>> you are making
>>> a IO-bound app, so threading doesn't buy you anything in performance and
>>> gives a big headache in data protection
Perhaps I misinterpr
when we work on the oops in the python then we have to pass the first
parameter as a self then the value of the other parameters .
for example:
class Student:
def __init__(self,name):
self.name=name
print 'The name is',self.name
a=student('sudhanshu')
a is an object of the student class
so __init
Greetings Sudanshu,
sudhanshu gautam wrote:
when we work on the oops in the python then we have to pass the first
parameter as a self then the value of the other parameters .
Well, not explicitly. If you're familiar with OOPS in C++, self is
analogous to the "this" pointer there. Also, you ne
sudhanshu gautam wrote:
Now If I placed the name of the constructor rather than the __init__
__baba___ so will it also work as a constructor or constructor has
specified already if yes then give me list of them
I'm not sure I parsed your question as you intended, but __init__ is
pretty much
Le Mon, 27 Apr 2009 22:38:30 +0530,
sudhanshu gautam s'exprima ainsi:
> Now If I placed the name of the constructor rather than the __init__
> __baba___ so will it also work as a constructor or constructor has specified
> already if yes then give me list of them
Actually __init__ is not the con
Offlist response...
Nice answer Denis, you neatly covered all the loose ends from
previous answers that I was just about to pick up on! :-)
"spir" wrote in message
news:20090427101523.5fc09...@o...
Le Sun, 26 Apr 2009 22:35:36 +0100,
Dayo Adewunmi s'exprima ainsi:
How can I
a) Open my she
Thanks for all the suggestions. I will have to try this.
--- On Sun, 26/4/09, Kent Johnson wrote:
From: Kent Johnson
Subject: Re: [Tutor] Lists in a file
To: "Robert Berman"
Cc: "David Holland" , "tutor python"
Date: Sunday, 26 April, 2009, 8:04 PM
On Sun, Apr 26, 2009 at 2:18 PM, Robert B
"sudhanshu gautam" wrote
Now If I placed the name of the constructor rather than the __init__
__baba___ so will it also work as a constructor or constructor has
specified
already if yes then give me list of them
Unlike some other OOP languages Python only has one constructor
(OK As Denis po
"Alan Gauld" wrote
Offlist response...
Oops, not offlist! Just as well I didn't say anything offensive! :-)
Alan G
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
Hi Bob, Shantanoo, Kent, and tutors,
Thank you Bob, Shantanoo, Kent for all the nice feedback. Exception
handling, the concept of states in cs, and the use of the for loop with
offset helped a lot. Here is the code I now have, based on your suggestions,
and it does what I need:
ListLines = [ line
14 matches
Mail list logo