Hello All! My name is Mazhar Hussain, and I am new to python, in fact, I am
new to programming as a whole. I dont know if its the right list to talk
about this.
I am really interested in 2d games, especially 2d games. I am also
interested in making games. I searched for a lot of programming langu
"Raj Medhekar" wrote
I would like to know how I could use the insert method in a
List matrix
OK, A list "matrix" is just a list containing other lists.
TThere is nothing special about it, it is just an ordinary list.
You could do it in two steps:
firstList = M[0]
firstList.insert(0,'pod')
"Mazhar Hussain" wrote
Hello All! My name is Mazhar Hussain, and I am new to python,
Welcome to the tutor list
new to programming as a whole. I dont know if its the right list to talk
about this.
Yes, we are here to help people learning Python, many of whom
are also learning programming.
Running time in CMD and IDLE
- Program running time is about the same in both CMD and IDLE
- The programs take a long time to run NOT because of runaway processes that
are using up memory
- The programs are being optimized with each successive generation to reduce
resources and time but the limit
Python Programming for the Absolute Beginner Second Edition.
Michael Dawson.
Boston, MA: Thomson Course Technology, 2006.
ISBN-13: 978-1-59863-112-8
ISBN-10: 1-59863-112-8
No experience required to learn Python programming.
This book will teach you the basics of Python programming
through simple g
Mazhar,
bhaaluu wrote:
> Python Programming for the Absolute Beginner Second Edition.
> Michael Dawson.
> Boston, MA: Thomson Course Technology, 2006.
> ISBN-13: 978-1-59863-112-8
> ISBN-10: 1-59863-112-8
This is, in my judgment, a good suggestion, provided you are working on
a Windows system. Oth
On Mon, Jul 20, 2009 at 6:00 AM, David wrote:
> Mazhar,
>
> bhaaluu wrote:
>> Python Programming for the Absolute Beginner Second Edition.
>> Michael Dawson.
>> Boston, MA: Thomson Course Technology, 2006.
>> ISBN-13: 978-1-59863-112-8
>> ISBN-10: 1-59863-112-8
> This is, in my judgment, a good sug
On Mon, Jul 20, 2009 at 2:04 AM, Mazhar Hussain wrote:
> Hello All! My name is Mazhar Hussain, and I am new to python, in fact, I
> am new to programming as a whole. I dont know if its the right list to talk
> about this.
> I am really interested in 2d games, especially 2d games. I am also
> in
Hi
This is the first code that I have programed. I think there is something
wrong with it. It is not a loop and computer seems wont bust. In the game,
ace will be fixed as low (value=1). And can you write documentation comments
for the first 39lines.
kind regards
Neo Gao
_
On Sun, Jul 19, 2009 at 4:34 PM, Michael wrote:
> I've been progressing steadily, until now. At this point, I have a pretty
> solid understanding of strings, integers, tuples, lists, dictionaries, etc.
> and everything up to functions vs. methods and the basics of classes and
> OOP. This is where
2009/7/20 GAONEO
> Hi
>
> This is the first code that I have programed. I think there is
> something wrong with it. It is not a loop and computer seems wont bust. In
> the game,
>
> ace will be fixed as low (value=1). And can you write documentation
> comments for the first 39lines.
>
>
yo
Thanks for all your help guys! I will try to buy all those books so that if
I find something in one book not understandable, I will look for it in
another book. Again Thanks. This list really is Helpful!
___
Tutor maillist - Tutor@python.org
http://mail
Thanks that works! But what if I wanted to modify 2 of the three lists in 2
different positions? Could you please let me know how I would go about doing
that?
Thanks!
-Raj
From: Ken Oliver
To: Raj Medhekar ; Python Tutor
Sent: Sunday, July 19, 2009 8:16:11
Hi everyone,
I'm working with a database of campaign finance filings, and I'm
trying to create a data structure that captures the fact that:
- there can be multiple races
- races can have multiple candidates
- candidates can have multiple campaign committees
- campaign committees can file m
Serdar Tumgoren wrote:
And of course, please let me know if there's a simpler approach I'm
overlooking that would meet my requirements.
As always, the advice is appreciated.
You could just create some classes with methods to handle the insertion
and deletion of those data.
You could also keep
Raj Medhekar wrote:
> Thanks that works! But what if I wanted to modify 2 of the three lists
> in 2 different positions? Could you please let me know how I would go
> about doing that?
M[0].insert(2, 'foo')
M[2].insert(1, 'bar')
___
Tutor maillist - T
"Serdar Tumgoren" wrote
I'm working with a database of campaign finance filings, and I'm
trying to create a data structure that captures the fact that:
- there can be multiple races
- races can have multiple candidates
- candidates can have multiple campaign committees
- campaign committe
> Have you considered using classes? This looks like a fairly natural fit for
> race, candidate, committee and maybe report casses
Aha, okay, the multiple classes approach makes sense. But would these
be nested classes, perhaps inheriting attributes from their parent
classes? E.g.:
class Race
Serdar Tumgoren wrote:
Hi everyone,
I'm working with a database of campaign finance filings, and I'm
trying to create a data structure that captures the fact that:
- there can be multiple races
- races can have multiple candidates
- candidates can have multiple campaign committees
- campa
On Fri, Jul 17, 2009 at 12:12:52PM -0400, Kent Johnson wrote:
> On Fri, Jul 17, 2009 at 11:42 AM, Sander Sweers
> wrote:
>
> > import time
> >
> > today = time.localtime()
> > datestr = time.strftime("%Y%m%d",today)
> > ext = ".tab"
> >
> > print datestr + ext
>
> You can include literal charact
I do not know paramiko but looking over the client documentations...
2009/7/20 Matt Herzog :
> if __name__ == "__main__":
>t = paramiko.Transport((hostname, port))
>t.connect(username=username, password=password)
>sftp = paramiko.SFTPClient.from_transport(t)
Up to here it looks fine.
On Mon, Jul 20, 2009 at 10:22:37PM +0200, Sander Sweers wrote:
> I do not know paramiko but looking over the client documentations...
>
> 2009/7/20 Matt Herzog :
> > if __name__ == "__main__":
> >t = paramiko.Transport((hostname, port))
> >t.connect(username=username, password=password)
>
2009/7/20 Matt Herzog :
> Traceback (most recent call last):
> File "./scpgetter.py", line 20, in ?
> sftp.get(remotepath, localpath)
> File "build/bdist.linux-x86_64/egg/paramiko/sftp_client.py", line 584,
> in get
> File "build/bdist.linux-x86_64/egg/paramiko/sftp_client.py
t;, line 682, in
> > _convert_status
> > ?? ?? ?? ?? ?? ?? ?? ??IOError: (2, '')
>
> Ah, now it get interesting. Genrally IOError means the file is not
> found. And looking at the source for _convert_status it is axactly
> that. The
2009/7/20 Matt Herzog :
> The file is there. I can sftp it using fugu.
I am sure it is but paramiko can't find it.
> The path is /20090720.tab since the file lives in a jail.
Issue a sftp.listdir() and see what paramiko sees on the remote server.
Gr
If I change
remotepath = 'datestr'
to
remotepath = datestr
I get:
sftp.get(remotepath, localpath)
File "build/bdist.linux-x86_64/egg/paramiko/sftp_client.py", line 587, in get
IOError: [Errno 21] Is a directory: '/tmp/testor/'
So remotepath is really more like a path + filname.
So I ne
A user of the paramiko mailing list said,
"Paramiko has an SFTPClient class and an SSHClient that can be used to
transfer files, why complicate it by using a Transport directly. The
easiest thing is to open an SSHClient:
2009/7/20 Matt Herzog :
> remotepath = 'datestr'
Ok, you are now making a string.
> remotepath = datestr
Like Kent wrote the datestr can include other characters. So I would
try "/%Y%m%d.tab".
> sftp.get(remotepath, localpath)
> File "build/bdist.linux-x86_64/egg/paramiko/sftp_client.py", line
Please reply to the list.
2009/7/20 Matt Herzog :
> Yeah. I have no idea if I am able to do this. The jail makes it ambiguous.
There is no difference, the jail just moves the root directory as seen
by the client.
Did you do as suggested earlier to use listdir()? This will tell you
how paramiko s
Hi , I am writing a python gtk application in which I am required to
fetch a large amount of data from web , now i want to create a wait
dialog for the user to know that I am still fetching data .The
question is how can i monitor that the required data has been fetched
. I could have a variable tha
On Mon, Jul 20, 2009 at 5:01 PM, Amit Sethi wrote:
> Hi , I am writing a python gtk application in which I am required to
> fetch a large amount of data from web , now i want to create a wait
> dialog for the user to know that I am still fetching data .The
> question is how can i monitor that the
On Mon, Jul 20, 2009 at 11:57:57PM +0200, Sander Sweers wrote:
> Please reply to the list.
>
> 2009/7/20 Matt Herzog :
> > Yeah. I have no idea if I am able to do this. The jail makes it ambiguous.
>
> There is no difference, the jail just moves the root directory as seen
> by the client.
>
> Di
On Mon, Jul 20, 2009 at 5:18 PM, Matt Herzog wrote:
> On Mon, Jul 20, 2009 at 11:57:57PM +0200, Sander Sweers wrote:
> > Please reply to the list.
> >
> > 2009/7/20 Matt Herzog :
> > > Yeah. I have no idea if I am able to do this. The jail makes it
> ambiguous.
> >
> > There is no difference, the
"Serdar Tumgoren" wrote
Aha, okay, the multiple classes approach makes sense. But would these
be nested classes,
No although they would probably have attributes containing
the related lists. Thus Race might have a list of Candidates.
And Candidate would have a list of Committees etc.
perh
rd=password)
> >sftp = paramiko.SFTPClient.from_transport(t)
> > print sftp.listdir()
> >t.close()
> >
> > It displays the contents of the dir no problem.
>
>
> Is the file present in the dir? What is it listed as? Is it just
> 07232009.tab (or simil
35 matches
Mail list logo