[Tutor] urgent help!!!!!!!!!!!

Prasad, Ramit ramit.prasad at jpmorgan.com
Fri Nov 18 00:43:10 CET 2011


def exchange(cash_in):
    euro=1
    dollar=1.35
    base=50
    if cash_in>base:
        totalreturn=cash_in*dollar
    else:
        totalreturn=0
    return totalreturn

amount=0
# this would be better placed inside the main function.
def main():
    while amount<50:
        amount = raw_input(float('how much do you want to change:'))
        # This should be 
    # amount = float( raw_input('how much do you want to change:' ) )
    if amount<50:
        total=0
        print 'enter an amount over 50: '
    else:
        total=exchange(amount)
        print 'Your exchange comes to: ',total


Ramit


Ramit Prasad | JPMorgan Chase Investment Bank | Currencies Technology
712 Main Street | Houston, TX 77002
work phone: 713 - 216 - 5423

--

This email is confidential and subject to important disclaimers and
conditions including on offers for the purchase or sale of
securities, accuracy and completeness of information, viruses,
confidentiality, legal privilege, and legal entity disclaimers,
available at http://www.jpmorgan.com/pages/disclosures/email.  


More information about the Tutor mailing list