# get a floating point number from user

from inputCheck import canBeFloat
# The file inputCheck.py has to be in the same place
# as this program for Python to find it.
# You can get inputCheck.py from the Mon 14 lecture. 

inStr = input("Enter interest rate: ")
# type sting; what the user typed

# canBeInt is True when the input can be converted
# to float
while not canBeFloat(inStr):
    # so we only get here if it can't be converted
    print("not a float!")
    inStr = input("Enter interest rate: ")

# if the while loop is over, we must finally have
# an input that can be converted
rate = float(inStr)
print("Interest rate is",rate)



