On Fri, 12 Dec 2008 04:05:21 -0800, feba wrote:

> that's it, thanks! was confused with it being basically in a column of
> all >= *.
> 
> I replaced it with
> 
>       if bank <= 0:
>               print("You're in the red!")
>               quit()
>       elif bank >= 1 and bank <= 9999:
>               rate = 0.0060

You can replace this with the simpler, easier to read and faster:

elif 1 <= bank <= 9999:
    rate = 0.0060
elif 10000 <= bank <= 24999:
    rate = 0.0085

...

>       elif bank >= 100000:
>               rate = 0.0173
>       else:
>               print("What's this doing here?")

Change the last two else clauses to this one:

else:
    rate = 0.0173



-- 
Steven
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to