Write a simple ATM program in Phython

Python Programming:  Write a simple ATM program.  Ask the user to enter their account number, and then print their beginning balance. (Just make one up).  Then ask them if they want to make a deposit or a withdrawal.  Depending on their selection, call a function to perform the action that they wish.  Then print the new balance.  They should be able to do as many transactions as they wish, so use iteration here.

input("Enter your Account Number")
print ("Current Account Balance: 25000")

strCHOICE = input ("Press 1 to make a Deposit or 2 to make a Withdrawal.")

if CHOICE == 1
    strDEPOSIT = input("Press 1 to deposit to checking, 2 for savings")
    if DEPOSIT = 1
    print("Please insert check or money now")
    elif DEPOSIT = 2
    print("Please insert check or money now")
 
elif CHOICE == 2
    strWITHDRAWAL = input("press 1 to draw funds from checking, press 2 for savings.")
    if WITHDRAWAL = 1
    input("How much would you like to withdraw today?")
    print("Please remove your cash from the slot below")
    elif WITHDRAWAL = 2
    input("How much would you like to withdraw today?")
    print("Please remove your cash from the slot below")

endofprogram = input("Thank you for your business, press enter to conclude this transaction.")

Function Key Codes for Python Curses

How to write a Function Key Codes for Python Curses ?


Function Key Codes in Curses on Python

Python 2.7.9 (default, Dec 11 2014, 04:42:00)
[GCC 4.9.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import curses
>>> int(curses.KEY_F1)
265
>>> int(curses.KEY_F2)
266
>>> int(curses.KEY_F3)
267
>>> int(curses.KEY_F4)
268
>>> int(curses.KEY_F5)
269
>>> int(curses.KEY_F6)
270
>>> int(curses.KEY_F7)
271
>>> int(curses.KEY_F8)
272
>>> int(curses.KEY_F9)
273
>>> int(curses.KEY_F10)
274
>>> int(curses.KEY_F11)
275
>>> int(curses.KEY_F12)
276

Phython - Temperature conversion code

How to write a Phython Temperature conversion code in Phython ?


T = float(input("Please enter the temperature: "))
      
unitFrom = input("Please enter the scale to convert from (Celsius, Kelvin, Fahrenheit): ")

unitTo = input("Please enter the scale to convert to (Celsius, Fahrenheit and Kelvin): ")


#T is the temperature converted, unitFrom is what scale it is entered in, unitTo is the scale converted to
def convertTemperature(T, unitFrom, unitTo):
    #From Fahrenheit to Celsius and Kelvin
    if unitFrom == "Fahrenheit":
        if unitTo == "Celsius":
            T = (T - 32)/1.8
        elif unitTo == "Kelvin":
            T = (T + 459.67)/1.8
           
    #From Celsius to Fahrenheit and Kelvin
    elif unitFrom == "Celsius":
        if unitTo == "Fahrenheit":
            T = 1.8*T + 32
        elif unitTo == "Kelvin":
            T = T + 273.15
           
    #From Kelvin to Celsius and Fahrenheit
    elif unitFrom == "Kelvin":
        if unitTo == "Celsius":
            T = T - 273.15
        elif unitTo == "Fahrenheit":
            T = 1.8*T - 459.67
       
    return T

#End