def calculate_difficulty(guess, slip):
    """
    How hard is this card for the typical learner?
    """

    # If guess + slip is greater than 1, then we have a degenerate card...
    # where the right answer lowers learned, and the wrong answer increases it
    if 1 > guess + slip:
        return float("inf")
    return calculate_correct(guess, slip, 0.5)
dataset/ETHPy150Open heiskr/sagefy/server/modules/sequencer/formulas.py/calculate_difficulty/swapped operands of `>`