# [Chicago] beginner help - role playing game

Alan Stern alans at risingrealty.com
Sun Dec 5 19:12:13 CET 2010

```Hi all.  My name is Al Stern.  I am an absolute beginner to programming and based on what I'd read, decided to try Python as my 1st language.  I am starting with a book called Python Programming for the Absolute Beginner by Michael Dawson.  The book has been pretty good and up to this point, I have grasped all the concepts it has covered.  At the end of each chapter, there are a number of challenges you need to complete before moving on.  Problem is, I have gotten stumped on one in Chapter 5: Lists and Dictionaries.

I'm not sure exactly how this mailing list works but was hoping someone here could give me some insight as to how to proceed.  Apologies if I am not posting the following in the correct format.  I just copied and pasted.)  Feel free to point me in the right direction if there are instructions as to how to do it.

Here is the challenge: Write a Character Creator program for a role-playing game. The player should be given a pool of 30 points to spend on four attributes: Strength, Health, Wisdom, and Dexterity. The >player should be able to spend points from the pool on any attribute and should also be able to take points from an attribute and put them back into the pool.

I think I did ok setting up the variables but haven't figured out where to go from there.

Here is what I have (along with my latest error message).  Thanks in advance.

# character creator / role playing game
# have 30 total points to work with

# set variables

attributes = ["strength", "health", "wisdom", "dexterity"]
points = [0,0,0,0]
MAX_POINTS = 30
available_points = MAX_POINTS - sum(points)

print("""
Our hero will need strength, health, wisdom and dexterity to survive.
You will have a limited amount of points to 'spend' on these attributes.
Use them wisely.  His life depends on it.
"""
)

# point allocation

print ("You have", available_points, "points available to use.")

for x in range(len(attributes)):
print ("\t",attributes[x], points[x])

for x in range(len(attributes)):
point_choice = input("\n\nHow many points do you want to assign to ",  attributes[x] , "?: ")

My error is:

Traceback (most recent call last):
File "C:/Users/Public/Documents/My Python programs/role_playing_game1.py", line 24, in <module>
point_choice = input("\n\nHow many points do you want to assign to ",  attributes[x] , "?: ")
TypeError: input expected at most 1 arguments, got 3

______________________
Alan Stern

Rising Realty
1820 W. Webster Ave #307
Chicago, IL 60614

(W)773-395-9999
(F)773-395-9553
(C)773-502-2556

www.risingrealty.com<http://www.risingrealty.com/>
Statement of Confidentiality
The contents of this e-mail message and its attachments are intended solely for the addressee(s) hereof. In addition, this e-mail transmission may be confidential and it may be subject to privilege protecting communications between attorneys or solicitors and their clients. If you are not the named addressee, or if this message has been addressed to you in error, you are directed not to read, disclose, reproduce, distribute, disseminate or otherwise use this transmission. Delivery of this message to any person other than the intended recipient(s) is not intended in any way to waive privilege or confidentiality.  If you have received this transmission in error, please alert the sender by reply e-mail; we also request that you immediately delete this message and its attachments, if any. Rising Realty reserve the right to monitor all e-mail communications through their networks.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/chicago/attachments/20101205/4fd9e4db/attachment.html>
```