def format_elapsed_seconds(elapsed_seconds):
    """
    Helper function to convert number of seconds to a string of hours, minutes, and seconds
    :param elapsed_seconds: float or int of the number of elapse seconds to format into a string
    :return: formatted time string
    """

    hours = int(elapsed_seconds / 3600.0)
    minutes = int(elapsed_seconds / 60.0 % 60)
    seconds = elapsed_seconds % 60.0

    time_string = '{:0.0f} hour{}, '.format(hours, 's' if hours != 1 else '') if hours >= 1 else ''
    time_string += '{:0.0f} minute{}, and '.format(minutes, 's' if minutes != 1 else '') if minutes >= 1 else ''
    time_string += '{:0.0f} second{}'.format(seconds, 's' if int(seconds) != 1 else '')

    return time_string