def getFloat(text=''):
    """Prompts user for a real number.
accepts any real number (in integer and decimal format)
returns the entered number
other inputs prompt user to re-enter a response"""
    while 1:
        print(text)
        try:
            userInput=float(input('Please enter a number:'))
            return userInput
        except: print('\nInvalid input - not recognized as a real number\n[Proper response required to exit loop]')