Newbie programmer needs a little help

Lars Urlich wildchild07770 at yahoo.com
Thu Apr 19 18:37:42 EDT 2001


Hi, i've been using computers for the last 11 years
now and i'm going 
to college this fall to start on my CS degree, so I
figured to start 
learning how to program and Python struck me as the
language to 
learn. Anyhow, i'm trying to write a simple database
program for a 
friend of mine to manage character sheets for an RPG
they play, I 
have a basic understanding of many of the simpler
functions of this 
language but alot of the functions I haven't quite
grasped yet, the 
ultimate goal of this btw is to port it onto his
handspring thru 
pippy.

Well here's my problem right now, I can't seem to open
or write any 
entered information into a simple text file. I've
tried many 
varations on the code posted and have a couple books
on the language 
and the examples they give don't seem to work. So any
help anyone 
could give me would be greatly appreciated.

this is what i've got just to try and test the idea of
the program 
the last 2 lines are just one of many variations i've
tried

from sys import *
print
print "Welcome to the LARP character program"
print
filename = raw_input("Please enter a path/filename: ")
filename = open 
print "Following are several character options"
playername = raw_input("What is your name? ")
charname = raw_input("Enter your character name: ")
nature = raw_input("What is the nature of your
character? ")
demeanor = raw_input("What is your demeanor? ")
info = [playername, charname, nature, demeanor]
print info

file = open(filename, list[0:3] "r") 
filename, "r"

Thanks,
Aaron


__________________________________________________
Do You Yahoo!?
Yahoo! Auctions - buy the things you want at great prices
http://auctions.yahoo.com/




More information about the Python-list mailing list