[noob] Error!

Jeff Shannon jeff at ccvcorp.com
Fri Feb 4 19:00:04 EST 2005


administrata wrote:

> Write a Car Salesman program [...]

This sounds like homework, and we generally try to avoid solving 
peoples' homework problems for them, but I can offer a suggestion.

> error occurs, i think the problem is in actual_price. but,
> I don't know how to comebine percentage and raw_input.
> help me...

It's hard to be sure since you don't say what the error is, nor 
anything about what you expect to see and what you actually see.

However, if you're pretty sure that the problem is the line where you 
calculate actual_price, then fire up an interactive interpreter and 
try fiddling with things.  You've got a lot of subexpressions there; 
pick some values and try each subexpression, one at a time, and take a 
look at what you get.

I bet that it won't take you long to figure out why you're not getting 
the result you expect.

Jeff Shannon
Technician/Programmer
Credit International




More information about the Python-list mailing list