On 24/03/16 18:12, Tom Maher wrote:
> raw_input('your input ')
Raw input returns a value, you need to store it somewhere like:
value = raw_input('your input ')
> while raw_input != 'c' or 'h' or 'l':
Then you need to compare vale not the function name.
(Did you learn BASIC at some point maybe?
Here is a simple game I am trying to create:
print "pick a number between 0 and 100 and tell me if it my guess is too
high (h) too low (l) or correct (c)"
guess = 0
print 'my guess is 50'
raw_input('your input ')
n = 50
while raw_input != 'c' or 'h' or 'l':
if raw_input == 'h':
"Corey Richardson" wrote
So far, I can use tuples/lists/dictionary's, and define some functions,
and a bit of other things.
Would it be hard for me to make a simple text rpg game? Or is there
something else I should know before I try that.
No idea about rpg because I've never played one fa
Hi Corey,
If this is going to be a command line program, two things that immediately
come to mind for me are: validating user input and persistence. If you put
something like "(1) to attack, (2) to run" what if the user types "yes", or
"Y", or "9"? You'll want to make sure your program doesn't cra
So far, I can use tuples/lists/dictionary's, and define some functions,
and a bit of other things.
Would it be hard for me to make a simple text rpg game? Or is there
something else I should know before I try that.
___
Tutor maillist - Tutor@python.o