[Tutor] python project books/webs from scratch? and python OOP

2007-05-15 Thread Jesus Rodriguez

Hi!

I have good python knowledge but I don't know how to face a project.Yes, i
can do some small projects, but i'm scared of big projectsI don't know
how to start!!

Then, I'm looking for a book or web with projects, like console text games
or console programs explained from scratch to finish.


On the other hand, I'm looking for book or tutorial of OO{P, D, A}
(programming, analisys and design) with python.


Thanks in advance.
___
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor


Re: [Tutor] Rock, Paper, Scissors

2006-08-12 Thread Jesus Rodriguez
Hi, i used a list with R, P, S like:rps = ["Rock", "Paper", "Scissors"]random.shuffle(rps)computerObject = rps[0]Then, the computer pick a random object and i compare my object with computer's object.
;)2006/8/11, wesley chun <[EMAIL PROTECTED]>:
> This looks like a fun project to work on.  From> reading the description, I feel this would be pretty> straight forward game to program.  However, I have no> idea how the computer would decide if it wanted a
> rock, paper, or a pair of scissors.  Any hints?christopher,this is indeed a *great* exercise... i've been using it since i can'tremember when... i had it as an exercise in BASIC and Pascal when i
was in high school, then turned it into an exercise for my C andPython courses.  naturally it's also in Core Python.others have said it and given code already, but this problem breaksdown into 3 discrete steps:
1. give values to R, P or S, i.e., an int, char, or some constant2. have the user choose one via its constant3. have the computer choose another -- you will need to randomly pickone of the 3 constants
4. logic to determine who the "winner" is of if it is a drawgood luck!-- wesley- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -"Core Python Programming", Prentice Hall, (c)2007,2001
http://corepython.comwesley.j.chun :: wescpy-at-gmail.compython training and technical consultingcyberweb.consulting : silicon valley, ca
http://cyberwebconsulting.com___Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
___
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor